84% just-writing

Code Review | Just Writing

WordPress plugin Just Writing scored 84% from 54 tests.

About plugin

  • Plugin page: just-writing
  • Plugin version: 3.9.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.0-6.2
  • WordPress version: 6.3.1
  • First release: Oct 24, 2013
  • Latest release: Apr 17, 2023
  • Number of updates: 220
  • Update frequency: every 15.7 days
  • Top authors: GregRoss (100%)

Code review

54 tests

User reviews

14 reviews

Install metrics

500+ active / 22,920 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.22MB] [CPU: ▼1.33ms] Passed 4 tests

This is a short check of server-side resources used by Just Writing
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.69 ▲0.2341.34 ▲2.39
Dashboard /wp-admin3.52 ▲0.2247.68 ▼0.93
Posts /wp-admin/edit.php3.64 ▲0.2850.86 ▲5.88
Add New Post /wp-admin/post-new.php6.11 ▲0.2286.49 ▼8.51
Media Library /wp-admin/upload.php3.45 ▲0.2236.78 ▲1.74
Just Writing /wp-admin/options-general.php?page=just-writing.4.5.php3.4132.22

Server storage [IO: ▲1.17MB] [DB: ▲0.00MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 69 new files
Database: no new tables, 7 new options
New WordPress options
just_writing_plugin_version
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Just Writing
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲9413.24 ▼1.331.95 ▲0.0441.30 ▼0.28
Dashboard /wp-admin2,210 ▲195.83 ▲0.9194.58 ▼8.9737.70 ▼0.20
Posts /wp-admin/edit.php2,093 ▲42.05 ▲0.0435.66 ▼0.7034.33 ▲1.80
Add New Post /wp-admin/post-new.php1,538 ▲1823.24 ▲0.10664.19 ▲3.6674.44 ▲11.54
Media Library /wp-admin/upload.php1,386 ▼24.17 ▼0.0191.80 ▼3.5241.90 ▲0.19
Just Writing /wp-admin/options-general.php?page=just-writing.4.5.php9651.9334.2945.18

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 7 options
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • just_writing_plugin_version
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/just-writing/ToolStack-WP-Utilities.class.php:33
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/just-writing/just-writing-install.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/just-writing/4.5/just-writing.4.5.php:351
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/just-writing/4.3/just-writing.4.3.php:351
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/just-writing/4.1/just-writing.4.1.php:351

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
1 plugin tags: admin posts writing dfw

just-writing/just-writing.php Passed 13 tests

Analyzing the main PHP file in "Just Writing" version 3.9.1
67 characters long description:
Adds more buttons to the distraction free writing mode command bar.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Everything looks great! No dangerous files found in this plugin11,290 lines of code in 39 files:
LanguageFilesBlank linesComment linesLines of code
PHP207069895,503
JavaScript107989433,498
CSS94321502,289

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity60.00
▷ Minimum class complexity60.00
▷ Maximum class complexity60.00
Average method complexity3.19
▷ Minimum method complexity1.00
▷ Maximum method complexity29.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods27
▷ Static methods00.00%
▷ Public methods2696.30%
▷ Protected methods00.00%
▷ Private methods13.70%
Functions86
▷ Named functions86100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
3 PNG files occupy 0.09MB with 0.03MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/JustWritingPen.png0.82KB0.81KB▼ 1.43%
images/just-writing-icons.png2.99KB1.66KB▼ 44.48%
images/logo-250.png83.45KB29.95KB▼ 64.11%