84% css-refresh-automatically

Code Review | CSS Refresh

WordPress plugin CSS Refresh scored 84% from 54 tests.

About plugin

  • Plugin page: css-refresh-autom...
  • Plugin version: 2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 2.0.2-3.4.1
  • WordPress version: 6.3.1
  • First release: Aug 20, 2012
  • Latest release: Aug 31, 2012
  • Number of updates: 27
  • Update frequency: every 0.4 days
  • Top authors: uniquewebdevelopment (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 2,481 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.17MB] [CPU: ▼11.16ms] Passed 4 tests

An overview of server-side resources used by CSS Refresh
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.43 ▼0.0435.51 ▼8.78
Dashboard /wp-admin3.19 ▼0.1135.84 ▼15.15
Posts /wp-admin/edit.php3.26 ▼0.1036.65 ▼13.82
Add New Post /wp-admin/post-new.php5.45 ▼0.4486.69 ▼3.34
Media Library /wp-admin/upload.php3.20 ▼0.0329.52 ▼6.89

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by CSS Refresh
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,821 ▲8613.36 ▼0.8534.74 ▲32.9442.66 ▲2.42
Dashboard /wp-admin2,209 ▲205.83 ▲0.96101.07 ▼11.5540.19 ▼0.04
Posts /wp-admin/edit.php2,101 ▲122.05 ▲0.0939.71 ▼2.0633.97 ▼2.04
Add New Post /wp-admin/post-new.php1,524 ▼923.25 ▼0.07611.45 ▼102.2061.51 ▲7.89
Media Library /wp-admin/upload.php1,397 ▲94.16 ▼0.0598.23 ▼4.8342.83 ▼2.48

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
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded

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 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/css-refresh-automatically/css-refresh.php:25

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, but this is not an exhaustive test

Optimizations

Plugin configuration 93% 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 require attention:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === css-refresh-automatically === )
The official readme.txt is a good inspiration

css-refresh-automatically/css-refresh.php 92% from 13 tests

The main PHP file in "CSS Refresh" ver. 2.1 adds more information about the plugin and also serves as the entry point for this plugin
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("css-refresh-automatically.php" instead of "css-refresh.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected137 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript11814110
PHP1192527

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.30
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
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 images were found in this plugin