74% postqueue

Code Review | Postqueue

WordPress plugin Postqueue scored 74% from 54 tests.

About plugin

  • Plugin page: postqueue
  • Plugin version: 1.5.0
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.0.2
  • WordPress version: 6.3.1
  • First release: Jun 5, 2015
  • Latest release: Oct 12, 2022
  • Number of updates: 40
  • Update frequency: every 67.2 days
  • Top authors: EdwardBock (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,579 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.09MB] [CPU: ▲2.31ms] Passed 4 tests

An overview of server-side resources used by Postqueue
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0747.00 ▼10.97
Dashboard /wp-admin3.43 ▲0.1356.26 ▲1.72
Posts /wp-admin/edit.php3.48 ▲0.1360.07 ▲6.01
Add New Post /wp-admin/post-new.php5.99 ▲0.11104.97 ▲12.47
Media Library /wp-admin/upload.php3.29 ▲0.0747.13 ▲12.90
Postqueues /wp-admin/tools.php?page=tools-postqueue3.2842.36

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 60 new files
Database: 2 new tables, 6 new options
New tables
wp_ph_postqueues
wp_ph_postqueue_contents
New WordPress options
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
db_upgraded
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Postqueue
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,807 ▲1813.27 ▼1.191.91 ▲0.0842.99 ▲0.88
Dashboard /wp-admin2,213 ▲44.84 ▼0.02111.83 ▲11.3843.84 ▲0.89
Posts /wp-admin/edit.php2,093 ▲72.02 ▼0.0437.82 ▲2.4134.90 ▲4.91
Add New Post /wp-admin/post-new.php6,493 ▲4,96020.39 ▼2.71958.38 ▲268.4340.62 ▼19.26
Media Library /wp-admin/upload.php1,389 ▲44.18 ▼0.02104.81 ▲1.9247.43 ▲6.01
Postqueues /wp-admin/tools.php?page=tools-postqueue8482.7450.1330.63

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • The plugin did not uninstall successfully, leaving 2 tables in the database
    • wp_ph_postqueue_contents
    • wp_ph_postqueues
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • 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
Good news, no errors were detected

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 items
  • 24× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Palasthotel\\WordPress\\BlockX\\Blocks\\_BlockType' not found in wp-content/plugins/postqueue/classes/Blocks/Postqueue.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'Postqueue\\Component\\Component' not found in wp-content/plugins/postqueue/classes/Editor.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Postqueue\\Component\\Component' not found in wp-content/plugins/postqueue/classes/REST.php:10
    • > PHP Notice
      Undefined variable: content in wp-content/plugins/postqueue/grid-templates/grid-box-postqueue.tpl.php on line 12
    • > PHP Fatal error
      Uncaught Error: Class 'Postqueue\\Component\\Database' not found in wp-content/plugins/postqueue/classes/Store.php:12
    • > PHP Warning
      include(wp-content/plugins/postqueue/templates/blockx__postqueue--single__editor.php): failed to open stream: No such file or directory in wp-content/plugins/postqueue/templates/blockx__postqueue--instance.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'Postqueue\\Component\\Component' not found in wp-content/plugins/postqueue/classes/Ajax.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/postqueue/partials/postqueue-metabox.tpl.php:10
    • > PHP Warning
      include(): Failed opening 'wp-content/plugins/postqueue/templates/blockx__postqueue--single__editor.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/postqueue/templates/blockx__postqueue--instance.php on line 3
    • > PHP Fatal error
      Uncaught Error: Interface 'Palasthotel\\WordPress\\Headless\\Interfaces\\IBlockPreparation' not found in wp-content/plugins/postqueue/classes/Headless/PostqueueBlockPreparation.php:10

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: order posts, queue, loop

postqueue/ph-postqueue.php 92% from 13 tests

The main file in "Postqueue" v. 1.5.0 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: Please rename the main PHP file in this plugin to the plugin slug ("postqueue.php" instead of "ph-postqueue.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin2,010 lines of code in 49 files:
LanguageFilesBlank linesComment linesLines of code
PHP394466891,696
JavaScript33839149
PO File13435112
CSS640553

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity5.84
▷ Minimum class complexity1.00
▷ Maximum class complexity47.00
Average method complexity1.97
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces8
Interfaces0
Traits0
Classes25
▷ Abstract classes416.00%
▷ Concrete classes2184.00%
▷ Final classes00.00%
Methods127
▷ Static methods64.72%
▷ Public methods12296.06%
▷ Protected methods00.00%
▷ Private methods53.94%
Functions25
▷ Named functions416.00%
▷ Anonymous functions2184.00%
Constants15
▷ Global constants00.00%
▷ Class constants15100.00%
▷ Public constants15100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin