84% rocketcdn

Code Review | RocketCDN - WordPress CDN Plugin

WordPress plugin RocketCDN - WordPress CDN Plugin scored84%from 54 tests.

About plugin

  • Plugin page: rocketcdn
  • Plugin version: 1.0.3
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4-6.3
  • WordPress version: 6.3.1
  • First release: Dec 20, 2021
  • Latest release: Aug 3, 2023
  • Number of updates: 16
  • Update frequency: every 37.1 days
  • Top authors: wp_media (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

200+ active /4,859 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.53MB] [CPU: ▼6.08ms] Passed 4 tests

Analyzing server-side resources used by RocketCDN - WordPress CDN Plugin
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.00 ▲0.5443.77 ▲3.83
Dashboard /wp-admin3.88 ▲0.5446.61 ▼17.98
Posts /wp-admin/edit.php3.93 ▲0.5849.59 ▲2.16
Add New Post /wp-admin/post-new.php6.40 ▲0.5284.20 ▼11.51
Media Library /wp-admin/upload.php3.74 ▲0.5237.83 ▲3.01
RocketCDN /wp-admin/options-general.php?page=rocketcdn3.7234.78

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 183 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

RocketCDN - WordPress CDN Plugin: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,831 ▲6013.73 ▼1.061.77 ▼0.3046.66 ▲3.87
Dashboard /wp-admin2,234 ▲465.84 ▲0.9898.73 ▼8.1040.81 ▲0.15
Posts /wp-admin/edit.php2,119 ▲302.04 ▼0.1135.28 ▼6.4834.40 ▼1.43
Add New Post /wp-admin/post-new.php1,537 ▲917.70 ▼0.53689.49 ▲35.3658.92 ▲3.63
Media Library /wp-admin/upload.php1,422 ▲404.25 ▲0.0196.11 ▼1.5842.03 ▲0.65
RocketCDN /wp-admin/options-general.php?page=rocketcdn9272.0523.2542.74

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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
The following issues need your attention
  • 133× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/FuelphpInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/AglInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/OsclassInstaller.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/BitrixInstaller.php:26
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/TastyIgniterInstaller.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/CiviCrmInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'RocketCDN\\Dependencies\\League\\Container\\ServiceProvider\\AbstractServiceProvider' not found in wp-content/plugins/rocketcdn/src/API/ServiceProvider.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/MODXEvoInstaller.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/ZendInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rocketcdn/vendor/composer/installers/src/Composer/Installers/MiaoxingInstaller.php:5

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
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
7 plugin tags: cdn plugin, cdn performance, wordpress cdn plugin, cdn, content delivery network...

rocketcdn/rocketcdn.php Passed 13 tests

This is the main PHP file of "RocketCDN - WordPress CDN Plugin" version 1.0.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
127 characters long description:
RocketCDN automatically rewrites all URLs to be served by our content delivery network (CDN). Easy CDN deployment to WordPress.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected5,883 lines of code in 180 files:
LanguageFilesBlank linesComment linesLines of code
PHP1681,1322,3864,916
CSS2670383
JSON300370
YAML3313123
JavaScript128188
SVG3003

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity3.46
▷ Minimum class complexity1.00
▷ Maximum class complexity47.00
Average method complexity2.29
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces18
Interfaces16
Traits2
Classes138
▷ Abstract classes32.17%
▷ Concrete classes13597.83%
▷ Final classes00.00%
Methods346
▷ Static methods236.65%
▷ Public methods28281.50%
▷ Protected methods3810.98%
▷ Private methods267.51%
Functions15
▷ Named functions213.33%
▷ Anonymous functions1386.67%
Constants6
▷ Global constants116.67%
▷ Class constants583.33%
▷ Public constants5100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin