10% client-crisis-clicri

Code Review | Client Crisis (CliCri)

WordPress plugin Client Crisis (CliCri) scored10%from 54 tests.

About plugin

  • Plugin page: client-crisis-clicri
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.4.2
  • WordPress version: 6.3.1
  • First release: Apr 1, 2016
  • Latest release: Apr 1, 2016
  • Number of updates: 4
  • Update frequency: every 1.7 days
  • Top authors: ulsteinmedia (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /589 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
It is recommended to fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Warning in wp-content/plugins/client-crisis-clicri/clicri_Plugin.php+35
    count(): Parameter must be an array or an object that implements Countable

Server metrics [RAM: ▲0.12MB] [CPU: ▼4.34ms] Passed 4 tests

Analyzing server-side resources used by Client Crisis (CliCri)
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.1254.28 ▲12.57
Dashboard /wp-admin3.43 ▲0.1248.21 ▼8.88
Posts /wp-admin/edit.php3.54 ▲0.1945.43 ▼9.41
Add New Post /wp-admin/post-new.php6.01 ▲0.1291.23 ▼1.03
Media Library /wp-admin/upload.php3.35 ▲0.1240.56 ▲1.97

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 14 new options
New WordPress options
clicri_Plugin__version
clicri_Plugin_BodyText
widget_theysaidso_widget
clicri_Plugin__installed
clicri_Plugin_Active
can_compress_scripts
clicri_Plugin_HeaderText
clicri_Plugin_ContactInfo
clicri_Plugin_ShowPostID
widget_recent-comments
...

Browser metrics Passed 4 tests

Client Crisis (CliCri): an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,832 ▲7114.36 ▲0.091.89 ▲0.1242.48 ▼2.71
Dashboard /wp-admin2,241 ▲645.64 ▲0.0390.35 ▼8.6938.21 ▼6.27
Posts /wp-admin/edit.php2,143 ▲432.05 ▲0.0633.96 ▼8.9632.01 ▼7.19
Add New Post /wp-admin/post-new.php1,539 ▲1123.30 ▲0.33670.53 ▼21.0755.32 ▼0.61
Media Library /wp-admin/upload.php1,441 ▲414.22 ▲0.0696.55 ▼10.5041.97 ▼2.55

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
Please fix the following items
  • This plugin does not fully uninstall, leaving 14 options in the database
    • db_upgraded
    • clicri_Plugin_ContactInfo
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • clicri_Plugin_BodyText
    • clicri_Plugin__installed
    • clicri_Plugin_Active
    • clicri_Plugin__version
    • widget_recent-posts
    • ...

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

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
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_head() in wp-content/plugins/client-crisis-clicri/clicri_template.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/client-crisis-clicri/clicri.php:77

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
6 plugin tags: dark, template, custom, emergency, crisis...

client-crisis-clicri/clicri.php 77% from 13 tests

The main PHP file in "Client Crisis (CliCri)" ver. 0.1 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Description: Keep the plugin description shorter than 140 characters (currently 147 characters long)
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("client-crisis-clicri.php" instead of "clicri.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected619 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP9223588595
SVG10124

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity8.67
▷ Minimum class complexity1.00
▷ Maximum class complexity38.00
Average method complexity1.62
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes233.33%
▷ Concrete classes466.67%
▷ Final classes00.00%
Methods77
▷ Static methods00.00%
▷ Public methods4761.04%
▷ Protected methods3038.96%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants00.00%
▷ Class constants2100.00%
▷ Public constants2100.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
PNG images were not found in this plugin