89% cc-deploy

Code Review | CC-Deploy

WordPress plugin CC-Deploy scored89%from 54 tests.

About plugin

  • Plugin page: cc-deploy
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8.2-4.9.4
  • WordPress version: 6.3.1
  • First release: Oct 12, 2017
  • Latest release: Mar 13, 2018
  • Number of updates: 3
  • Update frequency: every 51.0 days
  • Top authors: ClearcodeHQ (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /849 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.29MB] [CPU: ▼4.71ms] Passed 4 tests

Analyzing server-side resources used by CC-Deploy
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.78 ▲0.3241.55 ▼2.55
Dashboard /wp-admin3.63 ▲0.3251.37 ▲2.72
Posts /wp-admin/edit.php3.68 ▲0.3246.81 ▲0.37
Add New Post /wp-admin/post-new.php6.14 ▲0.2682.56 ▼18.51
Media Library /wp-admin/upload.php3.49 ▲0.2639.99 ▲1.87
Logs /wp-admin/admin.php?page=cc-deploy-logs3.4835.34
Settings /wp-admin/admin.php?page=cc-deploy-settings3.4833.47

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 57 new files
Database: 1 new table, 6 new options
New tables
wp_cc_deploy_log
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
db_upgraded
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

CC-Deploy: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,846 ▲10013.20 ▼1.201.85 ▲0.0842.99 ▲0.72
Dashboard /wp-admin2,242 ▲544.87 ▼0.02107.67 ▼2.9542.90 ▼2.26
Posts /wp-admin/edit.php2,125 ▲362.06 ▲0.0435.96 ▼0.3134.49 ▼1.09
Add New Post /wp-admin/post-new.php1,553 ▲3923.26 ▲5.58667.35 ▼6.5055.11 ▲7.96
Media Library /wp-admin/upload.php1,427 ▲364.23 ▼0.0298.04 ▼2.3443.03 ▼4.81
Logs /wp-admin/admin.php?page=cc-deploy-logs9212.0427.4526.47
Settings /wp-admin/admin.php?page=cc-deploy-settings1,0142.2022.5725.39

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Looking good! No server-side errors or output on direct access of PHP files

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

Optimizations

Plugin configuration 93% 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:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (**CC-Deploy Settings** - Visit the 'Deploy > Settings' page, select your preferred options and save them.), #2 (**CC-Deploy Logs** - Visit the 'Deploy > Logs' page to review latest deployment logs.)
You can look at the official readme.txt

cc-deploy/plugin.php 92% from 13 tests

The main file in "CC-Deploy" v. 1.0.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("cc-deploy.php" instead of "plugin.php")

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
No dangerous file extensions were detected1,407 lines of code in 34 files:
LanguageFilesBlank linesComment linesLines of code
PHP283303731,274
JSON300118
Markdown1508
CSS2007

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.45
Average class complexity15.08
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity2.69
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces4
Interfaces0
Traits0
Classes12
▷ Abstract classes18.33%
▷ Concrete classes1191.67%
▷ Final classes00.00%
Methods102
▷ Static methods2019.61%
▷ Public methods8684.31%
▷ Protected methods1312.75%
▷ Private methods32.94%
Functions4
▷ Named functions125.00%
▷ Anonymous functions375.00%
Constants3
▷ Global constants00.00%
▷ Class constants3100.00%
▷ Public constants3100.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
2 PNG files occupy 0.20MB with 0.13MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png115.15KB45.06KB▼ 60.86%
screenshot-2.png93.77KB34.41KB▼ 63.30%