10% webcl-widget

Code Review | WebCL Widget

WordPress plugin WebCL Widget scored10%from 54 tests.

About plugin

  • Plugin page: webcl-widget
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.6.0
  • WordPress version: 6.3.1
  • First release: Aug 19, 2013
  • Latest release: Aug 19, 2013
  • Number of updates: 21
  • Update frequency: every 3.2 days
  • Top authors: vinx77 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /721 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
These installer errors require your attention
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/webcl-widget/webcl-widget.php+187
    Function create_function() is deprecated

Server metrics [RAM: ▼1.96MB] [CPU: ▼52.63ms] Passed 4 tests

This is a short check of server-side resources used by WebCL Widget
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.434.83 ▼36.56
Dashboard /wp-admin2.05 ▼1.266.60 ▼40.02
Posts /wp-admin/edit.php2.05 ▼1.315.69 ▼44.92
Add New Post /wp-admin/post-new.php2.05 ▼3.845.15 ▼89.03
Media Library /wp-admin/upload.php2.05 ▼1.184.93 ▼31.62

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 5 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_webclwidget
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

WebCL Widget: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.39 ▼0.901.67 ▼0.5840.46 ▼5.28
Dashboard /wp-admin2,206 ▲185.91 ▲0.97107.67 ▲6.0337.53 ▼5.67
Posts /wp-admin/edit.php2,089 ▼02.04 ▼0.1340.40 ▲0.1436.18 ▼0.77
Add New Post /wp-admin/post-new.php1,533 ▼923.26 ▲4.91595.25 ▼49.9549.68 ▼22.89
Media Library /wp-admin/upload.php1,391 ▲64.18 ▼0.0792.40 ▼2.3041.22 ▲0.87

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin cannot be uninstalled
    • > Deprecated in wp-content/plugins/webcl-widget/webcl-widget.php+187
    Function create_function() is deprecated
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_webclwidget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/webcl-widget/webcl-widget.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
  • Donate link: Please fix this invalid URI: ""
You can take inspiration from this readme.txt

webcl-widget/webcl-widget.php Passed 13 tests

This is the main PHP file of "WebCL Widget" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
53 characters long description:
WebCL Widget shows which OpenCL devices are available

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
Everything looks great! No dangerous files found in this plugin148 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP12317148

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.10
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity1.75
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
2 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png11.79KB5.08KB▼ 56.96%
screenshot-2.png14.34KB6.19KB▼ 56.86%