84% mzz-stat

Code Review | Mzz-stat

WordPress plugin Mzz-stat scored84%from 54 tests.

About plugin

  • Plugin page: mzz-stat
  • Plugin version: 20170304.1423
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-4.7.2
  • WordPress version: 6.3.1
  • First release: Jan 1, 2016
  • Latest release: Mar 5, 2017
  • Number of updates: 15
  • Update frequency: every 28.7 days
  • Top authors: mjjojo (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /3,429 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

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

Server-side resources used by Mzz-stat
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0443.06 ▲1.74
Dashboard /wp-admin3.32 ▲0.0247.10 ▲1.27
Posts /wp-admin/edit.php3.38 ▲0.0243.45 ▼1.66
Add New Post /wp-admin/post-new.php5.91 ▲0.0284.44 ▼18.54
Media Library /wp-admin/upload.php3.25 ▲0.0234.95 ▲1.39
Mzz-stat /wp-admin/tools.php?page=mzz_mzzstat_admin3.2129.59

Server storage [IO: ▲0.02MB] [DB: ▲0.07MB] Passed 3 tests

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 3 new files
Database: 1 new table, 6 new options
New tables
wp_mzzstat_v2
New WordPress options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Mzz-stat
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲714.31 ▼0.061.67 ▼0.3149.21 ▲8.80
Dashboard /wp-admin2,202 ▲225.60 ▲0.0294.45 ▲1.8541.84 ▲1.37
Posts /wp-admin/edit.php2,104 ▲72.01 ▼0.0138.10 ▲1.0333.62 ▼11.37
Add New Post /wp-admin/post-new.php1,531 ▲523.14 ▲0.34597.40 ▼10.2270.50 ▲10.80
Media Library /wp-admin/upload.php1,407 ▲74.20 ▲0.02101.05 ▼1.7945.81 ▲0.79
Mzz-stat /wp-admin/tools.php?page=mzz_mzzstat_admin9911.9923.8533.73

Uninstaller [IO: ▲0.00MB] [DB: ▲0.07MB] 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: 6 options
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/mzz-stat/mzz-stat.php:31

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: page views, stats, statistics, visits per page per day, hit counter

mzz-stat/mzz-stat.php Passed 13 tests

"Mzz-stat" version 20170304.1423's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
54 characters long description:
A plugin that records statistics for a WordPress site.

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
No dangerous file extensions were detected120 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP28144120

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.12
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%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin