68% cluevo-lms

Code Review | CLUEVO LMS, E-Learning Platform

WordPress plugin CLUEVO LMS, E-Learning Platform scored68%from 54 tests.

About plugin

  • Plugin page: cluevo-lms
  • Plugin version: 1.12.4
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.3
  • WordPress version: 6.3.1
  • First release: Feb 13, 2019
  • Latest release: Oct 23, 2023
  • Number of updates: 93
  • Update frequency: every 18.6 days
  • Top authors: cluevo (100%)

Code review

54 tests

User reviews

15 reviews

Install metrics

800+ active /22,525 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.64MB] [CPU: ▲1.20ms] Passed 4 tests

This is a short check of server-side resources used by CLUEVO LMS, E-Learning Platform
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.01 ▲0.5445.68 ▲7.67
Dashboard /wp-admin3.97 ▲0.6258.69 ▼5.03
Posts /wp-admin/edit.php4.10 ▲0.7456.40 ▲8.01
Add New Post /wp-admin/post-new.php7.09 ▲1.2098.61 ▼5.87
Media Library /wp-admin/upload.php3.89 ▲0.6646.48 ▲11.05
Settings /wp-admin/admin.php?page=cluevo-settings3.9650.43
Learning Management /wp-admin/admin.php?page=cluevo-lms3.8996.20
User Management /wp-admin/admin.php?page=cluevo-users3.8641.33
LMS Posts /wp-admin/edit.php?post_type=cluevo-lms-metadata4.0272.18
Extensions /wp-admin/admin.php?page=cluevo-ext-page3.6729.59
Competence /wp-admin/admin.php?page=cluevo-competence3.8646.12
Reporting /wp-admin/admin.php?page=cluevo-reporting3.8852.83
Module Ratings /wp-admin/admin.php?page=cluevo-module-ratings3.8645.74

Server storage [IO: ▲14.73MB] [DB: ▲0.11MB] Passed 3 tests

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 195 new files
Database: 20 new tables, 15 new options
New tables
wp_cluevo_tree_dependencies
wp_cluevo_user_exp_log
wp_cluevo_languages
wp_cluevo_user_groups
wp_cluevo_scorm_parameters
wp_cluevo_tree_module_dependencies
wp_cluevo_modules
wp_cluevo_tree_modules
wp_cluevo_user_data
wp_cluevo_module_mime_types
...
New WordPress options
widget_theysaidso_widget
cluevo-exp-first-level
cluevo-lms-tree-1
cluevo-auto-add-new-users
cluevo-max-level
cluevo-modules-display-mode
cluevo-prepared-tree-1
cluevo-modules-display-position
db_upgraded
can_compress_scripts
...

Browser metrics Passed 4 tests

This is an overview of browser requirements for CLUEVO LMS, E-Learning Platform
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,990 ▲22914.80 ▲0.2821.19 ▲19.5928.54 ▼10.90
Dashboard /wp-admin2,262 ▲855.61 ▼0.0485.56 ▼0.7045.28 ▲1.55
Posts /wp-admin/edit.php2,174 ▲772.05 ▲0.0436.50 ▼0.3337.76 ▲2.78
Add New Post /wp-admin/post-new.php1,586 ▲6023.10 ▼0.07649.93 ▼27.2957.53 ▲0.05
Media Library /wp-admin/upload.php1,464 ▲614.23 ▲0.0599.65 ▲1.0446.38 ▲3.12
Settings /wp-admin/admin.php?page=cluevo-settings3,5602.9361.7754.47
Learning Management /wp-admin/admin.php?page=cluevo-lms2,2953.8170.2740.27
User Management /wp-admin/admin.php?page=cluevo-users1,9244.5760.5029.87
LMS Posts /wp-admin/edit.php?post_type=cluevo-lms-metadata2,3382.0435.2334.87
Extensions /wp-admin/admin.php?page=cluevo-ext-page3,8108.27358.28295.14
Competence /wp-admin/admin.php?page=cluevo-competence1,4882.2947.5833.62
Reporting /wp-admin/admin.php?page=cluevo-reporting1,5332.0828.1636.72
Module Ratings /wp-admin/admin.php?page=cluevo-module-ratings1,3972.1926.2228.64

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • The uninstall procedure failed, leaving 20 tables in the database
    • wp_cluevo_languages
    • wp_cluevo_competence_areas
    • wp_cluevo_competences_to_areas
    • wp_cluevo_tree
    • wp_cluevo_users_to_groups
    • wp_cluevo_user_groups
    • wp_cluevo_tree_dependencies
    • wp_cluevo_tree_module_dependencies
    • wp_cluevo_module_mime_types
    • wp_cluevo_tree_modules
    • ...
  • Zombie WordPress options detected upon uninstall: 15 options
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • cluevo-modules-display-mode
    • cluevo-max-level
    • widget_recent-comments
    • widget_theysaidso_widget
    • cluevo-exp-first-level
    • can_compress_scripts
    • cluevo-modules-display-position
    • ...

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
  • 59× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_header() in wp-content/plugins/cluevo-lms/templates/content-module-post.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/cluevo-lms/help/posts.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/cluevo-lms/classes/class.competence_area.inc.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/cluevo-lms/admin-views/class.module-ratings-page.php:12
    • > PHP Notice
      Undefined variable: item in wp-content/plugins/cluevo-lms/templates/part-toc-item.php on line 1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/cluevo-lms/help/permissions.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function cluevo_get_cluevo_lms() in wp-content/plugins/cluevo-lms/templates/part-dependency-list.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function cluevo_get_the_lms_user() in wp-content/plugins/cluevo-lms/templates/content-user-profile.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/cluevo-lms/admin-views/plugin-settings-page-general-settings.php:833
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/cluevo-lms/functions/functions.site-report.inc.php:6

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Please fix the following browser errors
    • > GET request to /wp-admin/admin.php?page=cluevo-ext-page
    • > Network (severe)
    https://www.paypalobjects.com/en_AT/i/scr/pixel.gif - Failed to load resource: the server responded with a status of 404 ()

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
  • Tags: You are using too many tags: 12 tag instead of maximum 10
The official readme.txt is a good inspiration

cluevo-lms/cluevo-lms.php 92% from 13 tests

The principal PHP file in "CLUEVO LMS, E-Learning Platform" v. 1.12.4 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

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
There were no executable files found in this plugin140,124 lines of code in 144 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript3315,47014,234106,446
PHP832,1611,36919,612
SVG21359,689
PO File32,0133,2814,373
CSS4054

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity33.45
▷ Minimum class complexity4.00
▷ Maximum class complexity77.00
Average method complexity3.33
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes11
▷ Abstract classes00.00%
▷ Concrete classes11100.00%
▷ Final classes00.00%
Methods150
▷ Static methods8355.33%
▷ Public methods12583.33%
▷ Protected methods00.00%
▷ Private methods2516.67%
Functions730
▷ Named functions59781.78%
▷ Anonymous functions13318.22%
Constants103
▷ Global constants9996.12%
▷ Class constants43.88%
▷ Public constants4100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
25 PNG files occupy 0.98MB with 0.28MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/icon-module-ui-pdf_256x256.png5.72KB3.51KB▼ 38.69%
images/icon-module-ui-audio_256x256.png8.82KB4.35KB▼ 50.71%
images/icon-module-ui-scorm-1-2_256x256.png11.10KB5.02KB▼ 54.76%
assets/screenshot-2.png23.51KB24.15KB0.00%
images/quiz_questions.png27.50KB28.15KB0.00%