84% hidden-posts

Code Review | Hidden Posts

WordPress plugin Hidden Posts scored84%from 54 tests.

About plugin

  • Plugin page: hidden-posts
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-3.8
  • WordPress version: 6.3.1
  • First release: Dec 19, 2013
  • Latest release: Dec 19, 2013
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: betzster (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

50+ active /4,452 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.02MB] [CPU: ▼9.97ms] Passed 4 tests

Server-side resources used by Hidden Posts
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.62 ▼4.09
Dashboard /wp-admin3.32 ▲0.0246.48 ▼9.69
Posts /wp-admin/edit.php3.37 ▲0.0248.07 ▼21.02
Add New Post /wp-admin/post-new.php5.90 ▲0.0297.26 ▼5.06
Media Library /wp-admin/upload.php3.24 ▲0.0238.20 ▼2.41

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Hidden Posts
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,840 ▲7913.15 ▼1.451.91 ▼0.0639.14 ▼4.62
Dashboard /wp-admin2,224 ▲215.89 ▲0.0294.49 ▼21.9639.13 ▼4.24
Posts /wp-admin/edit.php2,100 ▼22.07 ▲0.0538.49 ▼1.7035.64 ▼5.33
Add New Post /wp-admin/post-new.php1,549 ▲423.20 ▼0.22654.99 ▼46.3453.98 ▼7.65
Media Library /wp-admin/upload.php1,403 ▲34.22 ▼0.0599.16 ▼12.5843.83 ▼6.36

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
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/hidden-posts/hidden-posts.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
1 plugin tags: posts

hidden-posts/hidden-posts.php Passed 13 tests

The main PHP file in "Hidden Posts" ver. 0.1 adds more information about the plugin and also serves as the entry point for this plugin
28 characters long description:
Hide posts on the home page.

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
Good job! No executable or dangerous file extensions detected52 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1245052

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity10.00
▷ Minimum class complexity10.00
▷ Maximum class complexity10.00
Average method complexity2.29
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods342.86%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants00.00%
▷ Class constants3100.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
PNG images were not found in this plugin