84% jellyfish-counter-widget

Code Review | Jellyfish Counter Widget

WordPress plugin Jellyfish Counter Widget scored84%from 54 tests.

About plugin

  • Plugin page: jellyfish-counter...
  • Plugin version: 1.4.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.4
  • WordPress version: 6.3.1
  • First release: Jan 13, 2013
  • Latest release: Apr 2, 2020
  • Number of updates: 22
  • Update frequency: every 119.8 days
  • Top authors: toxicToad (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

2,000+ active /60,057 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.10MB] [CPU: ▼2.86ms] Passed 4 tests

An overview of server-side resources used by Jellyfish Counter Widget
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1037.32 ▼4.54
Dashboard /wp-admin3.41 ▲0.1048.23 ▼2.58
Posts /wp-admin/edit.php3.46 ▲0.1053.69 ▲5.50
Add New Post /wp-admin/post-new.php5.99 ▲0.1090.24 ▼7.32
Media Library /wp-admin/upload.php3.33 ▲0.1041.22 ▲2.99

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Jellyfish Counter Widget
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,795 ▲3414.24 ▼0.111.47 ▼0.2441.67 ▼1.78
Dashboard /wp-admin2,197 ▲235.64 ▲0.0996.85 ▼10.0442.90 ▼0.18
Posts /wp-admin/edit.php2,102 ▲22.02 ▲0.0035.79 ▼1.0036.21 ▲1.75
Add New Post /wp-admin/post-new.php1,528 ▼023.06 ▼0.11639.86 ▼50.7856.75 ▲8.45
Media Library /wp-admin/upload.php1,399 ▼44.16 ▼0.0598.65 ▼0.9542.73 ▼4.16

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 7 options
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_counter_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/jellyfish-counter-widget/jellyfish-counter-widget.php:30

User-side errors Passed 1 test

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

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
6 plugin tags: odometer, widget, milometer, animated, counter...

jellyfish-counter-widget/jellyfish-counter-widget.php Passed 13 tests

The principal PHP file in "Jellyfish Counter Widget" v. 1.4.4 is loaded by WordPress automatically on each request
71 characters long description:
Fully configurable static or animated odometer style rotating counters.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected916 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP14442510
JavaScript23054226
PO File13565100
CSS118380

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity63.00
▷ Minimum class complexity63.00
▷ Maximum class complexity63.00
Average method complexity16.50
▷ Minimum method complexity1.00
▷ Maximum method complexity29.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There are no PNG files in this plugin