84% wpr-halloween-scare-popup

Code Review | WPR Halloween Scare

WordPress plugin WPR Halloween Scare scored 84% from 54 tests.

About plugin

  • Plugin page: wpr-halloween-sca...
  • Plugin version: 1.6
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.1
  • WordPress version: 6.3.1
  • First release: Oct 28, 2014
  • Latest release: Jan 8, 2015
  • Number of updates: 22
  • Update frequency: every 3.2 days
  • Top authors: dunar21 (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active / 1,250 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼5.76ms] Passed 4 tests

This is a short check of server-side resources used by WPR Halloween Scare
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.41 ▼4.58
Dashboard /wp-admin3.32 ▲0.0246.88 ▼4.90
Posts /wp-admin/edit.php3.37 ▲0.0251.06 ▲5.76
Add New Post /wp-admin/post-new.php5.90 ▲0.0288.09 ▼18.84
Media Library /wp-admin/upload.php3.25 ▲0.0238.54 ▲5.30

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by WPR Halloween Scare
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲9014.44 ▼0.371.93 ▼0.4639.67 ▼7.07
Dashboard /wp-admin2,203 ▲155.85 ▲0.9697.36 ▼7.6838.74 ▼6.35
Posts /wp-admin/edit.php2,086 ▼32.02 ▼0.0439.64 ▲2.4436.48 ▲2.61
Add New Post /wp-admin/post-new.php1,532 ▲13523.42 ▲5.49672.68 ▲88.8357.76 ▲10.63
Media Library /wp-admin/upload.php1,388 ▼04.23 ▲0.0698.34 ▼2.4544.45 ▲1.77

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
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options

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)
Everything seems fine, however this is by no means an exhaustive test

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 add_action() in wp-content/plugins/wpr-halloween-scare-popup/halloweenscare.php:24

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Plugin Name: Please specify the plugin name on the first line ( === wpr-halloween-scare-popup === )
The official readme.txt might help

wpr-halloween-scare-popup/halloweenscare.php 92% from 13 tests

"WPR Halloween Scare" version 1.6's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wpr-halloween-scare-popup.php" instead of "halloweenscare.php")

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
Good job! No executable or dangerous file extensions detected145 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript113985
PHP1112460

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.55
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%
Functions3
▷ Named functions3100.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
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
imgs/OnebyOne.png0.11KB0.09KB▼ 13.64%