84% exit-popup

Code Review | Exit Popup

WordPress plugin Exit Popup scored84%from 54 tests.

About plugin

  • Plugin page: exit-popup
  • Plugin version: 3.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-6.0.3
  • WordPress version: 6.3.1
  • First release: Jun 27, 2016
  • Latest release: Oct 22, 2022
  • Number of updates: 38
  • Update frequency: every 60.8 days
  • Top authors: nimonogi (86.84%)mohsenr1 (15.79%)

Code review

54 tests

User reviews

24 reviews

Install metrics

2,000+ active /74,475 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.06MB] [CPU: ▼7.58ms] Passed 4 tests

An overview of server-side resources used by Exit Popup
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.0748.28 ▲5.41
Dashboard /wp-admin3.41 ▲0.0249.46 ▼17.43
Posts /wp-admin/edit.php3.52 ▲0.1348.81 ▼5.29
Add New Post /wp-admin/post-new.php5.99 ▲0.0687.97 ▼13.01
Media Library /wp-admin/upload.php3.33 ▲0.0644.63 ▲5.62
Exit Popup /wp-admin/options-general.php?page=exit-popup-settings3.3343.63

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
can_compress_scripts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Exit Popup: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,906 ▲12014.79 ▲0.536.06 ▲3.7146.09 ▲4.31
Dashboard /wp-admin2,202 ▲255.66 ▲0.0888.99 ▼1.4041.57 ▲1.19
Posts /wp-admin/edit.php2,104 ▲41.97 ▲0.0141.14 ▲5.8537.11 ▼0.94
Add New Post /wp-admin/post-new.php1,529 ▲323.67 ▲0.63682.76 ▲15.1055.84 ▼5.70
Media Library /wp-admin/upload.php1,401 ▲44.22 ▲0.0696.93 ▼3.8247.88 ▲3.88
Exit Popup /wp-admin/options-general.php?page=exit-popup-settings1,0821.9134.0434.82

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There are user-side issues you should fix
    • > GET request to /wp-admin/options-general.php?page=exit-popup-settings
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28609 "jQuery.Deferred exception: jQuery(...).wpColorPicker is not a function" "TypeError: jQuery(...).wpColorPicker is not a function\n at HTMLDocument.\u003Canonymous> (/wp-admin/options-general.php?page=exit-popup-settings:262:53)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:27292)" undefined
    • > GET request to /wp-admin/options-general.php?page=exit-popup-settings
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28721 Uncaught TypeError: jQuery(...).wpColorPicker is not a function

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Screenshots: Add images for these screenshots: #1 (Popup Window screenshot-1.png), #2 (Plugin Settings screenshot-2.png)
  • Tags: You are using too many tags: 26 tag instead of maximum 10
Please take inspiration from this readme.txt

exit-popup/exit-popup.php Passed 13 tests

"Exit Popup" version 3.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
86 characters long description:
Exit Popup enables you to display a jQuery modal before a visitor leaves your website.

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
Good job! No executable or dangerous file extensions detected547 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP27123335
CSS1238147
SVG10141
JavaScript20824

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.29
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%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.25MB with 0.08MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png54.96KB53.17KB▼ 3.24%
screenshot-1.png204.35KB82.91KB▼ 59.43%