78% disable-post-password

Code Review | Disable Post Passwords

WordPress plugin Disable Post Passwords scored78%from 54 tests.

About plugin

  • Plugin page: disable-post-pass...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4.2-4.3
  • WordPress version: 6.3.1
  • First release: Nov 1, 2012
  • Latest release: Aug 20, 2015
  • Number of updates: 5
  • Update frequency: every 204.6 days
  • Top authors: unknowndomain (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,263 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
Install script ran successfully

Server metrics [RAM: ▼0.36MB] [CPU: ▼22.86ms] Passed 4 tests

A check of server-side resources used by Disable Post Passwords
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▼0.0133.43 ▼3.12
Dashboard /wp-admin3.23 ▼0.1228.25 ▼32.37
Posts /wp-admin/edit.php3.29 ▼0.0733.10 ▼15.79
Add New Post /wp-admin/post-new.php4.64 ▼1.2542.54 ▼39.62
Media Library /wp-admin/upload.php3.23 ▼0.0031.48 ▼3.65
Post Passwords /wp-admin/options-general.php?page=disable-post-passwords3.2027.73

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Disable Post Passwords
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.24 ▼1.341.71 ▼0.0940.87 ▼1.17
Dashboard /wp-admin2,213 ▲274.84 ▼0.0497.29 ▼25.2339.53 ▼6.56
Posts /wp-admin/edit.php2,093 ▲71.97 ▼0.0936.97 ▼0.6731.74 ▼4.24
Add New Post /wp-admin/post-new.php1,547 ▲1418.35 ▼4.92609.01 ▼56.6566.15 ▼2.80
Media Library /wp-admin/upload.php1,395 ▲74.15 ▼0.0596.69 ▼8.5139.88 ▼5.13
Post Passwords /wp-admin/options-general.php?page=disable-post-passwords8642.0723.2327.65

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
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=disable-post-passwords
    • > User deprecated in wp-includes/functions.php+5828
    Hook contextual_help is deprecated since version 3.3.0! Use get_current_screen()->add_help_tab(), get_current_screen()->remove_help_tab() instead.

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/disable-post-password/disable_post_passwords.php:38

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Screenshot #1 (From this panel you can select which users should have post passwords disabled.) image missing
Please take inspiration from this readme.txt

disable-post-password/disable_post_passwords.php 92% from 13 tests

The main file in "Disable Post Passwords" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("disable-post-password.php" instead of "disable_post_passwords.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected150 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP16771150

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code1.32
Average class complexity55.00
▷ Minimum class complexity55.00
▷ Maximum class complexity55.00
Average method complexity7.75
▷ Minimum method complexity1.00
▷ Maximum method complexity35.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
1 PNG file occupies 0.02MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png23.61KB7.31KB▼ 69.05%