84% customize-private-protected

Code Review | Customize Private & Protected - Change or remove title prefix and more

WordPress plugin Customize Private & Protected - Change or remove title prefix and more scored84%from 54 tests.

About plugin

  • Plugin page: customize-private...
  • Plugin version: 1.3.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8-6.2.2
  • WordPress version: 6.3.1
  • First release: Aug 31, 2021
  • Latest release: Jul 3, 2023
  • Number of updates: 21
  • Update frequency: every 32.0 days
  • Top authors: kirkclarke (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

100+ active /1,532 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 gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼7.03ms] Passed 4 tests

Server-side resources used by Customize Private & Protected - Change or remove title prefix and more
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.54 ▲1.60
Dashboard /wp-admin3.32 ▼0.0345.97 ▼19.41
Posts /wp-admin/edit.php3.37 ▲0.0147.98 ▼2.00
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.74 ▼7.63
Media Library /wp-admin/upload.php3.24 ▲0.0134.22 ▲0.94

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
db_upgraded
widget_recent-comments
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

Customize Private & Protected - Change or remove title prefix and more: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,802 ▲5613.27 ▼1.081.53 ▼0.0539.83 ▼2.29
Dashboard /wp-admin2,206 ▲185.83 ▲0.0298.50 ▼14.2340.13 ▼1.85
Posts /wp-admin/edit.php2,092 ▲32.12 ▲0.1335.73 ▼3.3037.89 ▲1.04
Add New Post /wp-admin/post-new.php1,514 ▼1417.63 ▼5.70649.01 ▲5.9556.01 ▼2.94
Media Library /wp-admin/upload.php1,379 ▼64.19 ▼0.0196.21 ▼7.9242.81 ▼1.56

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
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded

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 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/customize-private-protected/customize-private-protected.php:384

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes:
  • Tags: You are using too many tags: 12 tag instead of maximum 10
You can look at the official readme.txt

customize-private-protected/customize-private-protected.php Passed 13 tests

The principal PHP file in "Customize Private & Protected - Change or remove title prefix and more" v. 1.3.0 is loaded by WordPress automatically on each request
86 characters long description:
Use WP Customize to modify elements of password protected and private posts and pages.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin524 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP190104411
JavaScript112161
CSS25152

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions14
▷ Named functions1285.71%
▷ Anonymous functions214.29%
Constants0
▷ Global constants00.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
There are no PNG files in this plugin