78% eight-day-week-print-workflow

Code Review | Eight Day Week Print Workflow

WordPress plugin Eight Day Week Print Workflow scored 78% from 54 tests.

About plugin

  • Plugin page: eight-day-week-pr...
  • Plugin version: 1.1.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.5
  • WordPress version: 5.8.1
  • First release: Nov 16, 2015
  • Latest release: Oct 9, 2020
  • Number of updates: 7
  • Update frequency: every 256.4 days
  • Top authors: 10upbot (57.14%)joshlevinson (42.86%)jsternberg (28.57%)

Code review

54 tests

User reviews

2 reviews

Install metrics

20+ active / 1,921 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▲0.84MB] [CPU: ▼134.49ms] Passed 4 tests

An overview of server-side resources used by Eight Day Week Print Workflow
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.68 ▲0.9642.13 ▲19.97
Dashboard /wp-admin3.90 ▲0.8448.40 ▲4.21
Posts /wp-admin/edit.php3.95 ▲0.8543.70 ▲9.70
Add New Post /wp-admin/post-new.php6.26 ▲0.83100.65 ▼550.65
Media Library /wp-admin/upload.php3.84 ▲0.8339.17 ▼1.22
Dummy Submenu /wp-admin/edit.php?post_type=print-issue&page=removeme3.6532.38

Server storage [IO: ▲0.20MB] [DB: ▲0.01MB] Passed 3 tests

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 26 new files
Database: no new tables, 1 new option
New WordPress options
edw_activated

Browser metrics Passed 4 tests

Eight Day Week Print Workflow: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,752 ▲15615.72 ▲0.158.24 ▼0.1650.58 ▲4.76
Dashboard /wp-admin3,022 ▲886.00 ▲0.09138.94 ▲4.36109.54 ▲2.78
Posts /wp-admin/edit.php2,789 ▲502.69 ▼0.0164.91 ▲2.1290.10 ▲2.70
Add New Post /wp-admin/post-new.php1,647 ▲3221.62 ▼0.15285.57 ▲20.18102.81 ▼15.17
Media Library /wp-admin/upload.php1,856 ▲465.01 ▼0.00141.47 ▼7.44117.76 ▼3.04
Dummy Submenu /wp-admin/edit.php?post_type=print-issue&page=removeme280.900.0410.74

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • This plugin did not uninstall successfully, leaving 1 option in the database
    • edw_activated

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for 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: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/eight-day-week-print-workflow/includes/functions/articles.php on line 76
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Eight_Day_Week\\Plugins\\add_filter() in wp-content/plugins/eight-day-week-print-workflow/plugins.php:19
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/eight-day-week-print-workflow/includes/functions/articles.php on line 76
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/eight-day-week-print-workflow/includes/functions/articles.php on line 76
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Eight_Day_Week\\Plugins\\add_filter() in wp-content/plugins/eight-day-week-print-workflow/plugins.php:19

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Please fix the following user-side errors
    • > GET request to /wp-admin/edit.php?post_type=print-issue&page=removeme
    • > Network (severe)
    wp-admin/edit.php?post_type=print-issue&page=removeme - Failed to load resource: the server responded with a status of 500 (Internal Server Error)

Optimizations

Plugin configuration 96% from 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
3 plugin tags: print, workflow, editorial

eight-day-week-print-workflow/eight-day-week.php 92% from 13 tests

The main file in "Eight Day Week Print Workflow" v. 1.1.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("eight-day-week-print-workflow.php" instead of "eight-day-week.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin4,097 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
PHP187721,5922,365
JavaScript33381471,495
Sass2307141
CSS229896

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity10.22
▷ Minimum class complexity2.00
▷ Maximum class complexity22.00
Average method complexity2.46
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces16
Interfaces0
Traits0
Classes9
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes00.00%
Methods57
▷ Static methods610.53%
▷ Public methods5596.49%
▷ Protected methods00.00%
▷ Private methods23.51%
Functions168
▷ Named functions15793.45%
▷ Anonymous functions116.55%
Constants11
▷ Global constants11100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin