63% wptimize

Code Review | WPtimize

WordPress plugin WPtimize scored63%from 54 tests.

About plugin

  • Plugin page: wptimize
  • Plugin version: 1.1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.8
  • WordPress version: 6.3.1
  • First release: Dec 5, 2016
  • Latest release: Jun 16, 2017
  • Number of updates: 41
  • Update frequency: every 4.6 days
  • Top authors: YossiAharon (100%)

Code review

54 tests

User reviews

1 review

Install metrics

60+ active /2,092 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▼1.25MB] [CPU: ▼49.99ms] Passed 4 tests

Server-side resources used by WPtimize
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.74 ▼0.7312.84 ▼27.29
Dashboard /wp-admin2.78 ▼0.5713.77 ▼49.10
Posts /wp-admin/edit.php2.78 ▼0.5813.89 ▼32.16
Add New Post /wp-admin/post-new.php2.78 ▼3.1113.03 ▼91.41
Media Library /wp-admin/upload.php2.78 ▼0.4515.54 ▼19.58
WPtimize /wp-admin/options-general.php?page=wptimize2.7818.80

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for WPtimize
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲6013.57 ▼0.781.70 ▼0.2338.98 ▼4.93
Dashboard /wp-admin2,212 ▲244.84 ▼0.18110.25 ▼8.2043.35 ▼2.01
Posts /wp-admin/edit.php2,092 ▲32.01 ▼0.0535.93 ▼1.1729.86 ▼2.09
Add New Post /wp-admin/post-new.php1,535 ▲2122.97 ▲5.47668.89 ▲1.5069.09 ▲20.59
Media Library /wp-admin/upload.php1,397 ▲94.20 ▼0.0198.53 ▼14.1841.22 ▼7.49
WPtimize /wp-admin/options-general.php?page=wptimize1,1552.0429.0829.04

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > Notice in wp-content/plugins/wptimize/public/class-wptimize-public.php+114
    Trying to access array offset on value of type bool
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
  • 36 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wptimize
    • > Notice in wp-content/plugins/wptimize/admin/partials/wptimize-admin-display.php+58
    Trying to access array offset on value of type bool
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wptimize
    • > Notice in wp-content/plugins/wptimize/admin/partials/wptimize-admin-display.php+228
    A non well formed numeric value encountered

SRP 0% 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
Please fix the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/wptimize/public/partials/wptimize-public-display.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/wptimize/admin/partials/wptimize-admin-display.php:20

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)
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
5 plugin tags: cleanup, clean, header, head, optimization

wptimize/wptimize.php Passed 13 tests

The primary PHP file in "WPtimize" version 1.1.1 is used by WordPress to initiate all plugin functionality
46 characters long description:
Optimization and cleanup plugin for WordPress.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected642 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP12195599593
JavaScript2103143
CSS2296

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity9.29
▷ Minimum class complexity1.00
▷ Maximum class complexity38.00
Average method complexity2.27
▷ Minimum method complexity1.00
▷ Maximum method complexity37.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods38
▷ Static methods25.26%
▷ Public methods3386.84%
▷ Protected methods00.00%
▷ Private methods513.16%
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

Often times overlooked, PNG files can occupy unnecessary space in your plugin
PNG images were not found in this plugin