83% wp-pranks

Code Review | WP Pranks

WordPress plugin WP Pranks scored83%from 54 tests.

About plugin

  • Plugin page: wp-pranks
  • Plugin version: 1.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.3.2
  • WordPress version: 6.3.1
  • First release: Jan 27, 2020
  • Latest release: Jan 27, 2020
  • Number of updates: 17
  • Update frequency: every 25.4 days
  • Top authors: qwerks (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /726 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
The plugin installed successfully, without throwing any errors or notices

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

This is a short check of server-side resources used by WP Pranks
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0042.89 ▼2.33
Dashboard /wp-admin3.32 ▲0.0246.91 ▼7.76
Posts /wp-admin/edit.php3.37 ▲0.0154.83 ▼1.52
Add New Post /wp-admin/post-new.php5.90 ▲0.0186.15 ▼12.40
Media Library /wp-admin/upload.php3.24 ▲0.0139.82 ▲0.15
WP Pranks /wp-admin/options-general.php?page=webv-pranks-setting-admin3.2230.26

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
db_upgraded
widget_recent-posts
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for WP Pranks
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,796 ▲3514.31 ▼0.041.97 ▼0.3645.62 ▲1.09
Dashboard /wp-admin2,202 ▲315.65 ▲0.0787.95 ▼2.5041.15 ▲0.54
Posts /wp-admin/edit.php2,104 ▲72.03 ▼0.0839.32 ▲0.8537.50 ▼0.59
Add New Post /wp-admin/post-new.php1,529 ▲323.00 ▼0.15663.40 ▼15.6854.30 ▼2.29
Media Library /wp-admin/upload.php1,398 ▼24.16 ▼0.0497.65 ▼14.1143.94 ▼6.69
WP Pranks /wp-admin/options-general.php?page=webv-pranks-setting-admin8752.0036.1930.85

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

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
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-pranks/pranks.php:96

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that need to be fixed:
  • Screenshots: Screenshot #1 (None) image missing
  • Donate link: Please fix this invalid url: "None"
You can take inspiration from this readme.txt

wp-pranks/pranks.php 92% from 13 tests

The principal PHP file in "WP Pranks" v. 1.0 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("wp-pranks.php" instead of "pranks.php")

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
There were no executable files found in this plugin153 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP11730153

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.47
Average class complexity18.00
▷ Minimum class complexity18.00
▷ Maximum class complexity18.00
Average method complexity3.83
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.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

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