84% special-admins

Code Review | Special Admin

WordPress plugin Special Admin scored 84% from 54 tests.

About plugin

  • Plugin page: special-admins
  • Plugin version: 0.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1-3.8
  • WordPress version: 6.3.1
  • First release: Dec 18, 2013
  • Latest release: Dec 20, 2013
  • Number of updates: 4
  • Update frequency: every 0.5 days
  • Top authors: tott (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 599 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼1.89ms] Passed 4 tests

A check of server-side resources used by Special Admin
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0342.45 ▲1.88
Dashboard /wp-admin3.32 ▲0.0247.10 ▼1.08
Posts /wp-admin/edit.php3.37 ▲0.0149.46 ▼3.87
Add New Post /wp-admin/post-new.php5.90 ▲0.0199.13 ▲1.54
Media Library /wp-admin/upload.php3.24 ▲0.0132.99 ▼4.13
Special Admin /wp-admin/options-general.php?page=special-admin3.1828.86

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Special Admin
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲9413.36 ▼0.944.77 ▲2.6144.97 ▼3.44
Dashboard /wp-admin2,210 ▲255.77 ▼0.0999.79 ▼10.8141.21 ▼3.49
Posts /wp-admin/edit.php2,093 ▲42.00 ▲0.0238.71 ▼1.1137.08 ▼0.42
Add New Post /wp-admin/post-new.php1,523 ▼1023.18 ▼0.12675.56 ▼24.6467.08 ▲8.10
Media Library /wp-admin/upload.php1,389 ▲14.20 ▲0.00101.86 ▼10.0141.18 ▼5.49
Special Admin /wp-admin/options-general.php?page=special-admin6621.356.9315.24

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/special-admins/special-admins.php on line 417
    • > PHP Notice
      Undefined variable: argv in wp-content/plugins/special-admins/special-admins.php on line 417

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 93% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need your attention:
  • Tags: The plugin tags were not defined
You can take inspiration from this readme.txt

special-admins/special-admins.php 92% from 13 tests

Analyzing the main PHP file in "Special Admin" version 0.1.0
The following require your attention:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin434 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP14684297
JavaScript21653102
JSON10025
Markdown55010
CSS1070

PHP code Passed 2 tests

An short overview of 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.42
Average class complexity48.00
▷ Minimum class complexity48.00
▷ Maximum class complexity48.00
Average method complexity3.94
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods16
▷ Static methods212.50%
▷ Public methods16100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
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
No PNG files were detected