89% crankwheel

Code Review | CrankWheel Instant Demos

WordPress plugin CrankWheel Instant Demos scored 89% from 54 tests.

About plugin

  • Plugin page: crankwheel
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.4.2
  • WordPress version: 6.3.1
  • First release: Nov 8, 2017
  • Latest release: Sep 24, 2020
  • Number of updates: 11
  • Update frequency: every 95.5 days
  • Top authors: joisig (90.91%)hoddmachine (18.18%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active / 1,049 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▼0.58MB] [CPU: ▼16.74ms] Passed 4 tests

Analyzing server-side resources used by CrankWheel Instant Demos
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1042.29 ▲0.87
Dashboard /wp-admin3.40 ▲0.1044.01 ▼3.12
Posts /wp-admin/edit.php3.51 ▲0.1645.91 ▼2.39
Add New Post /wp-admin/post-new.php3.27 ▼2.6137.64 ▼62.31
Media Library /wp-admin/upload.php3.32 ▲0.1037.00 ▲4.03

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 23 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
_cw_api_first_activation
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for CrankWheel Instant Demos
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,836 ▲10113.37 ▼1.011.70 ▼0.3343.50 ▼8.59
Dashboard /wp-admin2,242 ▲605.87 ▼0.0299.78 ▼2.5139.98 ▼4.66
Posts /wp-admin/edit.php2,125 ▲332.06 ▲0.0535.33 ▼7.2934.05 ▼2.93
Add New Post /wp-admin/post-new.php1,543 ▲2418.44 ▼4.80662.23 ▲50.9969.82 ▲14.14
Media Library /wp-admin/upload.php1,422 ▲374.20 ▲0.0197.99 ▼2.1142.48 ▼2.38

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • This plugin does not fully uninstall, leaving 7 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • _cw_api_first_activation
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded

Smoke tests Passed 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 Passed 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
  • Tags: Please reduce the number of tags, currently 37 tag instead of maximum 10
You can look at the official readme.txt

crankwheel/crankwheel.php 85% from 13 tests

"CrankWheel Instant Demos" version 1.0.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 290 characters long)
  • Domain Path: The domain path folder was not found ("/languages")

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
Everything looks great! No dangerous files found in this plugin564 lines of code in 18 files:
LanguageFilesBlank linesComment linesLines of code
PHP14348397501
Markdown137056
JSON1005
CSS1001
JavaScript1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity3.50
▷ Minimum class complexity1.00
▷ Maximum class complexity10.00
Average method complexity1.59
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces9
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods34
▷ Static methods25.88%
▷ Public methods3088.24%
▷ Protected methods00.00%
▷ Private methods411.76%
Functions11
▷ Named functions981.82%
▷ Anonymous functions218.18%
Constants5
▷ Global constants5100.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
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
dist/images/icon-admin-menu_6af7a1fe.png0.71KB0.71KB0.00%