84% remove-css-link-ids

Code Review | Remove CSS link IDs

WordPress plugin Remove CSS link IDs scored84%from 54 tests.

About plugin

  • Plugin page: remove-css-link-ids
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-3.9
  • WordPress version: 6.3.1
  • First release: May 10, 2014
  • Latest release: Dec 31, 2014
  • Number of updates: 7
  • Update frequency: every 33.7 days
  • Top authors: cyman (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /1,781 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.62ms] Passed 4 tests

Analyzing server-side resources used by Remove CSS link IDs
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0040.92 ▼1.20
Dashboard /wp-admin3.31 ▲0.0151.66 ▼0.34
Posts /wp-admin/edit.php3.36 ▲0.0051.71 ▲0.78
Add New Post /wp-admin/post-new.php5.89 ▲0.0088.72 ▼17.40
Media Library /wp-admin/upload.php3.24 ▲0.0038.59 ▲0.47

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Remove CSS link IDs
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.41 ▲0.051.88 ▼0.1139.18 ▼9.20
Dashboard /wp-admin2,195 ▲155.63 ▼0.0385.90 ▼6.7539.24 ▼1.30
Posts /wp-admin/edit.php2,100 ▼02.02 ▲0.0439.13 ▲1.3434.78 ▼4.24
Add New Post /wp-admin/post-new.php1,528 ▲223.26 ▼0.09646.31 ▼19.7958.61 ▲5.24
Media Library /wp-admin/upload.php1,403 ▲34.18 ▼0.0499.09 ▼7.8043.20 ▼1.11

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

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
Please take a closer look at the following
  • 8× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      require_once(): Failed opening required '/tmp/wordpress-tests-lib/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/remove-css-link-ids/tests/bootstrap.php on line 6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/remove-css-link-ids/trunk/remove-css-link-ids.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/remove-css-link-ids/tests/test-sample.php:3
    • > PHP Warning
      require_once(/tmp/wordpress-tests-lib/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/remove-css-link-ids/trunk/tests/bootstrap.php on line 6
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/remove-css-link-ids/trunk/tests/test-sample.php:3
    • > PHP Warning
      require_once(/tmp/wordpress-tests-lib/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/remove-css-link-ids/tests/bootstrap.php on line 6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/remove-css-link-ids/remove-css-link-ids.php:21
    • > PHP Fatal error
      require_once(): Failed opening required '/tmp/wordpress-tests-lib/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/remove-css-link-ids/trunk/tests/bootstrap.php on line 6

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)
No browser issues were found

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:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === remove-css-link-ids === )
You can look at the official readme.txt

remove-css-link-ids/remove-css-link-ids.php Passed 13 tests

This is the main PHP file of "Remove CSS link IDs" version 1.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
115 characters long description:
WP plugin that removes the ID attributes from the tags for the CSS files. Used mostly together with mod_pagespeed.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin108 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
Bourne Shell115459
PHP3141435
XML10014

PHP code Passed 2 tests

This is a short overview 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.08
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG files were detected