79% risk-list

Code Review | Risk List

WordPress plugin Risk List scored79%from 54 tests.

About plugin

  • Plugin page: risk-list
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.7
  • WordPress version: 6.3.1
  • First release: Jan 9, 2017
  • Latest release: Jan 9, 2017
  • Number of updates: 6
  • Update frequency: N/A
  • Top authors: mikemayhem3030 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,209 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.63MB] [CPU: ▼1.15ms] Passed 4 tests

Analyzing server-side resources used by Risk List
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.13 ▲0.6748.08 ▲2.36
Dashboard /wp-admin3.95 ▲0.6050.66 ▼11.94
Posts /wp-admin/edit.php4.03 ▲0.6755.49 ▲1.73
Add New Post /wp-admin/post-new.php6.54 ▲0.65128.90 ▲33.03
Media Library /wp-admin/upload.php3.84 ▲0.6041.97 ▲3.25
Processs /wp-admin/edit.php?post_type=risklist_process3.8843.45
Risks /wp-admin/edit.php?post_type=risklist_risk3.8840.97
Actions /wp-admin/edit.php?post_type=risklist_action3.8840.22
Objectives /wp-admin/edit.php?post_type=risklist_objective3.8839.14
Controls /wp-admin/edit.php?post_type=risklist_control3.8840.72
Metrics /wp-admin/edit.php?post_type=risklist_metric3.8842.36

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 35 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Risk List
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,380 ▲64513.53 ▼0.701.73 ▼0.2446.95 ▼6.98
Dashboard /wp-admin2,768 ▲5915.14 ▼0.51104.71 ▲3.0948.62 ▲5.15
Posts /wp-admin/edit.php2,190 ▲872.39 ▲0.4042.62 ▲7.4338.26 ▲1.49
Add New Post /wp-admin/post-new.php1,595 ▲6923.39 ▲5.92655.27 ▼60.2941.41 ▼19.17
Media Library /wp-admin/upload.php1,474 ▲774.56 ▲0.41100.53 ▼7.7549.71 ▲3.82
Processs /wp-admin/edit.php?post_type=risklist_process1,1582.3738.3029.95
Risks /wp-admin/edit.php?post_type=risklist_risk1,2002.3835.0227.87
Actions /wp-admin/edit.php?post_type=risklist_action1,1662.3642.3229.35
Objectives /wp-admin/edit.php?post_type=risklist_objective1,1792.3633.9530.11
Controls /wp-admin/edit.php?post_type=risklist_control1,1872.3935.0728.58
Metrics /wp-admin/edit.php?post_type=risklist_metric1,1872.4933.6028.75

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 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
Please fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/risk-list/risk-list.php:20

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Please take a look at the following user-side issues
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=risklist_metric
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28609 "jQuery.Deferred exception: jQuery(...).sortable is not a function" "TypeError: jQuery(...).sortable is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/risk-list/js/main.js?ver=6.3.1:129:34)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:27292)" undefined
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=risklist_metric
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28721 Uncaught TypeError: jQuery(...).sortable is not a function

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
2 plugin tags: risks, risk management

risk-list/risk-list.php Passed 13 tests

Analyzing the main PHP file in "Risk List" version 1.0
75 characters long description:
Risk List is Risk Management Software running on the WordPress CMS platform

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected12,317 lines of code in 23 files:
LanguageFilesBlank linesComment linesLines of code
CSS1022697,647
PHP45471842,442
JavaScript63271411,281
SVG200914
HTML11033

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.45
Average class complexity13.40
▷ Minimum class complexity9.00
▷ Maximum class complexity27.00
Average method complexity4.10
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes10
▷ Abstract classes00.00%
▷ Concrete classes10100.00%
▷ Final classes00.00%
Methods40
▷ Static methods00.00%
▷ Public methods40100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions38
▷ Named functions38100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.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
2 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
html/before-you-go/assets/zbs_logo.png23.62KB9.98KB▼ 57.76%
html/before-you-go/assets/risklistweb.png1.96KB1.33KB▼ 32.15%