76% cm-curated-list-manager

Code Review | CM Curated List Manager

WordPress plugin CM Curated List Manager scored 76% from 54 tests.

About plugin

  • Plugin page: cm-curated-list-m...
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-5.9
  • WordPress version: 5.9.2
  • First release: Apr 14, 2016
  • Latest release: Jan 26, 2022
  • Number of updates: 114
  • Update frequency: every 18.5 days
  • Top authors: CreativeMindsSolutions (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

100+ active / 6,077 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.68MB] [CPU: ▼289.92ms] 75% from 4 tests

Analyzing server-side resources used by CM Curated List Manager
Please take the time to fix the following items
  • CPU: Total CPU usage must kept under 500.00ms (currently 1,390.32ms on /wp-admin/admin.php?page=cmlm-options)
PageMemory (MB)CPU Time (ms)
Home /4.24 ▲0.7258.54 ▲1.37
Dashboard /wp-admin4.09 ▲0.6836.55 ▲1.35
Posts /wp-admin/edit.php4.32 ▲0.6744.25 ▲3.94
Add New Post /wp-admin/post-new.php7.62 ▲0.6497.72 ▼1,165.08
Media Library /wp-admin/upload.php4.04 ▲0.7427.80 ▲2.70
Options /wp-admin/admin.php?page=cmlm-options4.211,390.32
Upgrade ➤ /wp-admin/admin.php?page=cmlm_pro4.0226.33
Categories /wp-admin/edit-tags.php?taxonomy=cmlm_category4.0428.04
Links /wp-admin/edit-tags.php?taxonomy=cmlm_link4.0529.38
User Guide /wp-admin/admin.php?page=cmlm_about4.1525.37

Server storage [IO: ▲0.89MB] [DB: ▲0.01MB] Passed 3 tests

Filesystem and database footprint
No storage issues were detected
Filesystem: 80 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for CM Curated List Manager
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,846 ▲12416.19 ▲0.487.25 ▲1.382.14 ▼0.12
Dashboard /wp-admin2,945 ▲876.08 ▼0.16116.70 ▼24.90173.02 ▲6.57
Posts /wp-admin/edit.php2,741 ▲473.24 ▲0.0163.94 ▲1.22148.12 ▼0.69
Add New Post /wp-admin/post-new.php1,693 ▲1916.14 ▼6.28403.89 ▼36.41151.97 ▼9.43
Media Library /wp-admin/upload.php1,751 ▲535.51 ▲0.10144.29 ▲7.82197.89 ▲9.34
Options /wp-admin/admin.php?page=cmlm-options3,2006.00137.25280.89
Upgrade ➤ /wp-admin/admin.php?page=cmlm_pro1,5353.4563.73171.18
Categories /wp-admin/edit-tags.php?taxonomy=cmlm_category1,6543.1768.33130.92
Links /wp-admin/edit-tags.php?taxonomy=cmlm_link1,7082.9167.58128.30
User Guide /wp-admin/admin.php?page=cmlm_about5,58813.76361.16253.87

Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 0% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=cmlm_about
    • > Warning in wp-content/plugins/cm-curated-list-manager/bundle/licensing/cminds-free.php+2989
    mysqli_get_server_info() expects exactly 1 parameter, 0 given

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 3× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/cm-curated-list-manager/views/backend/options/nav.php
    • > /wp-content/plugins/cm-curated-list-manager/views/backend/taxonomies/common/quick_edit_custom_box_raw.php
    • > /wp-content/plugins/cm-curated-list-manager/views/backend/taxonomies/common/quick_edit_custom_box.php
  • 22× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'com\\cminds\\listmanager\\App' not found in wp-content/plugins/cm-curated-list-manager/views/backend/taxonomies/link/edit_form_fields.php:11
    • > PHP Notice
      Undefined variable: name in wp-content/plugins/cm-curated-list-manager/views/backend/taxonomies/common/quick_edit_custom_box.php on line 6
    • > PHP Fatal error
      Uncaught Error: Class 'com\\cminds\\listmanager\\plugin\\taxonomies\\TaxonomyAbstract' not found in wp-content/plugins/cm-curated-list-manager/plugin/taxonomies/LinkTaxonomy.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'com\\cminds\\listmanager\\App' not found in wp-content/plugins/cm-curated-list-manager/views/backend/options/template.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function com\\cminds\\listmanager\\plugin_dir_path() in wp-content/plugins/cm-curated-list-manager/cm-list-manager.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'com\\cminds\\listmanager\\App' not found in wp-content/plugins/cm-curated-list-manager/views/frontend/shortcodes/error.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'com\\cminds\\listmanager\\App' not found in wp-content/plugins/cm-curated-list-manager/bundle/licensing/cminds-plugin-config.php:6
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/cm-curated-list-manager/views/backend/taxonomies/common/quick_edit_custom_box.php on line 6
    • > PHP Notice
      Undefined variable: input_html in wp-content/plugins/cm-curated-list-manager/views/backend/taxonomies/common/quick_edit_custom_box_raw.php on line 6
    • > PHP Notice
      Undefined variable: submenus in wp-content/plugins/cm-curated-list-manager/views/backend/options/nav.php on line 6

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
These are user-side errors you should fix
    • > GET request to /wp-admin/admin.php?page=cmlm-options
    • > Other (warning) in unknown
    /wp-admin/admin.php?page=cmlm-options 869 Allow attribute will take precedence over 'allowfullscreen'.
    • > GET request to /wp-admin/admin.php?page=cmlm_about
    • > Console-api (severe) in unknown
    https://static.xx.fbcdn.net/rsrc.php/v3/yK/r/0vXAIXjdJnT.js?_nc_x=Ij3Wp8lg5Kz 57:562 "ErrorUtils caught an error:\n\nCannot listen to an undefined element. [Caught in: Tried to listen to element of type click]\n\nSubsequent non-fatal errors won't be logged; see https://fburl.com/debugjs."

Optimizations

Plugin configuration 90% 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: You can look at the official readme.txt

cm-curated-list-manager/cm-list-manager.php 85% from 13 tests

The primary PHP file in "CM Curated List Manager" version 1.1.0 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("cm-curated-list-manager.php" instead of "cm-list-manager.php")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 179 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected5,737 lines of code in 40 files:
LanguageFilesBlank linesComment linesLines of code
PHP298483754,847
CSS4938717
JavaScript72318173

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity22.12
▷ Minimum class complexity1.00
▷ Maximum class complexity248.00
Average method complexity3.15
▷ Minimum method complexity1.00
▷ Maximum method complexity38.00
Code structure
Namespaces10
Interfaces0
Traits0
Classes16
▷ Abstract classes212.50%
▷ Concrete classes1487.50%
▷ Final classes00.00%
Methods160
▷ Static methods2113.12%
▷ Public methods13986.88%
▷ Protected methods159.38%
▷ Private methods63.75%
Functions4
▷ Named functions00.00%
▷ Anonymous functions4100.00%
Constants23
▷ Global constants14.35%
▷ Class constants2295.65%
▷ Public constants22100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
36 PNG files occupy 0.50MB with 0.14MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
bundle/licensing/views/img/Vector.png0.54KB0.43KB▼ 19.31%
bundle/licensing/css/images/ui-icons_2e83ff_256x240.png4.44KB4.17KB▼ 6.02%
bundle/licensing/css/images/ui-bg_glass_75_e6e6e6_1x400.png0.26KB0.15KB▼ 42.37%
bundle/licensing/views/WPmembership.png35.89KB11.14KB▼ 68.95%
bundle/licensing/views/img/v2.png0.38KB0.37KB▼ 1.79%