84% max-css

Code Review | Max CSS

WordPress plugin Max CSS scored84%from 54 tests.

About plugin

  • Plugin page: max-css
  • Plugin version: 1.1
  • PHP compatiblity: 5.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-5.8.2
  • WordPress version: 6.3.1
  • First release: Nov 13, 2019
  • Latest release: Mar 7, 2022
  • Number of updates: 10
  • Update frequency: every 84.6 days
  • Top authors: myapos (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /2,807 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
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼6.07ms] Passed 4 tests

This is a short check of server-side resources used by Max CSS
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.09 ▼11.35
Dashboard /wp-admin3.31 ▲0.0145.11 ▼4.48
Posts /wp-admin/edit.php3.36 ▲0.0150.28 ▼2.62
Add New Post /wp-admin/post-new.php5.91 ▲0.0397.92 ▼5.82
Media Library /wp-admin/upload.php3.24 ▲0.0136.14 ▼1.48

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Max CSS
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲2913.24 ▼1.431.71 ▼0.4242.09 ▼1.19
Dashboard /wp-admin2,209 ▲216.05 ▲0.16110.66 ▲2.2542.01 ▼3.66
Posts /wp-admin/edit.php2,092 ▲32.03 ▼0.0240.22 ▲0.9434.74 ▼4.88
Add New Post /wp-admin/post-new.php1,514 ▼2817.80 ▼0.45649.77 ▼1.4559.54 ▲2.85
Media Library /wp-admin/upload.php1,379 ▼64.21 ▲0.0097.03 ▼9.9341.23 ▼2.44

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% 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
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/max-css/includes/maxcss-styles.php:21
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/max-css/includes/maxcss-scripts.php:26

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 96% from 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: editor, maxcss, maximize, icon, css...

max-css/maxCSS.php 92% from 13 tests

The primary PHP file in "Max CSS" version 1.1 is used by WordPress to initiate all plugin functionality
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("max-css.php" instead of "maxCSS.php")

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
There were no executable files found in this plugin107 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript110356
PHP3181545
CSS1006

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.33
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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin