84% filter-for-jetpack-site-stats

Code Review | Filter for Jetpack Site Stats

WordPress plugin Filter for Jetpack Site Stats scored 84% from 54 tests.

About plugin

  • Plugin page: filter-for-jetpac...
  • Plugin version: 2.0.0
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Sep 14, 2022
  • Latest release: May 30, 2023
  • Number of updates: 19
  • Update frequency: every 13.6 days
  • Top authors: colwellj (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 621 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▼0.69MB] [CPU: ▼13.58ms] Passed 4 tests

Analyzing server-side resources used by Filter for Jetpack Site Stats
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0137.04 ▼4.24
Dashboard /wp-admin3.31 ▲0.0048.36 ▼0.95
Posts /wp-admin/edit.php3.36 ▲0.0047.03 ▲0.71
Add New Post /wp-admin/post-new.php3.12 ▼2.7636.97 ▼49.85
Media Library /wp-admin/upload.php3.23 ▲0.0038.52 ▲1.15

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Filter for Jetpack Site Stats
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲1113.62 ▲0.321.62 ▼0.1142.99 ▲0.28
Dashboard /wp-admin2,209 ▲34.86 ▲0.0398.36 ▼14.7439.97 ▼1.76
Posts /wp-admin/edit.php2,086 ▼31.99 ▼0.0535.57 ▲1.2432.31 ▼3.34
Add New Post /wp-admin/post-new.php1,534 ▼823.21 ▲0.34653.47 ▼24.3254.18 ▼3.20
Media Library /wp-admin/upload.php1,391 ▲34.22 ▼0.01108.18 ▼4.1246.82 ▼2.34

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 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
The following issues need your attention
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function FilterForJetpackSiteStats\\add_action() in wp-content/plugins/filter-for-jetpack-site-stats/filter-for-jetpack-site-stats.php:42

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that need to be fixed: Please take inspiration from this readme.txt

filter-for-jetpack-site-stats/filter-for-jetpack-site-stats.php Passed 13 tests

Analyzing the main PHP file in "Filter for Jetpack Site Stats" version 2.0.0
67 characters long description:
Enables admins to filter "Top Posts & Pages" summaries by metadata.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected290 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript17543182
PHP1261564
CSS111544

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.16
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
Namespaces1
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 functions266.67%
▷ Anonymous functions133.33%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG files were detected