78% professional-opt-in

Code Review | Professional Opt-in

WordPress plugin Professional Opt-in scored 78% from 54 tests.

About plugin

  • Plugin page: professional-opt-in
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.5.2
  • WordPress version: 5.8.1
  • First release: Aug 1, 2013
  • Latest release: Aug 1, 2013
  • Number of updates: 4
  • Update frequency: N/A
  • Top authors: KenMorico (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,626 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
Installer ran successfully

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

A check of server-side resources used by Professional Opt-in
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.1334.03 ▲11.79
Dashboard /wp-admin3.07 ▲0.0237.18 ▼5.19
Posts /wp-admin/edit.php3.13 ▲0.0241.74 ▼3.39
Add New Post /wp-admin/post-new.php5.43 ▼0.0089.17 ▼565.32
Media Library /wp-admin/upload.php3.02 ▲0.0235.00 ▲3.77
Professional Opt-in /wp-admin/options-general.php?page=professional_opt_in2.9628.10

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 1 new option
New WordPress options
professional_opt_in_options

Browser metrics Passed 4 tests

An overview of browser requirements for Professional Opt-in
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,698 ▲10216.43 ▲0.789.90 ▲0.4845.64 ▲0.94
Dashboard /wp-admin2,972 ▲355.98 ▼0.10152.72 ▲7.76116.38 ▲2.39
Posts /wp-admin/edit.php2,744 ▲52.72 ▲0.0065.76 ▼0.0181.23 ▼6.82
Add New Post /wp-admin/post-new.php1,507 ▼17618.49 ▼0.25360.77 ▼10.31112.03 ▲6.34
Media Library /wp-admin/upload.php1,815 ▲55.04 ▲0.01141.25 ▼15.53113.94 ▼3.05
Professional Opt-in /wp-admin/options-general.php?page=professional_opt_in1,1002.0855.9471.06

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 1 option
    • professional_opt_in_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
    • > GET request to /wp-admin/options-general.php?page=professional_opt_in
    • > Notice in wp-content/plugins/professional-opt-in/professional-opt-in.php+140
    Undefined index: p1_promotext
    • > GET request to /wp-admin/options-general.php?page=professional_opt_in
    • > Notice in wp-content/plugins/professional-opt-in/professional-opt-in.php+146
    Undefined index: p1_ctatext
    • > GET request to /wp-admin/options-general.php?page=professional_opt_in
    • > Notice in wp-content/plugins/professional-opt-in/professional-opt-in.php+151
    Undefined index: p1_ctaurl
    • > GET request to /wp-admin/options-general.php?page=professional_opt_in
    • > Notice in wp-content/plugins/professional-opt-in/professional-opt-in.php+157
    Undefined index: p1_showhome
    • > GET request to /wp-admin/options-general.php?page=professional_opt_in
    • > Notice in wp-content/plugins/professional-opt-in/professional-opt-in.php+164
    Undefined index: p1_showposts
    • > GET request to /wp-admin/options-general.php?page=professional_opt_in
    • > Notice in wp-content/plugins/professional-opt-in/professional-opt-in.php+171
    Undefined index: p1_showpages
    • > GET request to /wp-admin/options-general.php?page=professional_opt_in
    • > Notice in wp-content/plugins/professional-opt-in/professional-opt-in.php+178
    Undefined index: p1_showarchives
    • > GET request to /wp-admin/options-general.php?page=professional_opt_in
    • > Notice in wp-content/plugins/professional-opt-in/professional-opt-in.php+185
    Undefined index: p1_active

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/professional-opt-in/professional-opt-in.php:49

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === professional-opt-in === )
  • Screenshots: These screenshots require images: #1 (Buttons on a post page.), #2 (Settings Screen)
Please take inspiration from this readme.txt

professional-opt-in/professional-opt-in.php Passed 13 tests

The main PHP file in "Professional Opt-in" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
40 characters long description:
An opt-in plugin for professional sites.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin270 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP17243173
CSS113563
JavaScript1161034

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions21
▷ Named functions21100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
3 PNG files occupy 0.11MB with 0.07MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png21.41KB6.73KB▼ 68.57%
images/logo.png6.41KB3.39KB▼ 47.08%
screenshot-2.png89.39KB26.10KB▼ 70.80%