78% easy-dash-for-learndash

Code Review | Easy Dash for LearnDash

WordPress plugin Easy Dash for LearnDash scored78%from 54 tests.

About plugin

  • Plugin page: easy-dash-for-lea...
  • Plugin version: 2.4.1
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.4
  • WordPress version: 6.3.1
  • First release: Jul 21, 2021
  • Latest release: Oct 27, 2023
  • Number of updates: 29
  • Update frequency: every 28.6 days
  • Top authors: maurolopes (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

900+ active /8,208 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.63ms] Passed 4 tests

Analyzing server-side resources used by Easy Dash for LearnDash
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0036.03 ▼0.78
Dashboard /wp-admin3.31 ▲0.0043.87 ▼3.43
Posts /wp-admin/edit.php3.36 ▲0.0046.94 ▲0.81
Add New Post /wp-admin/post-new.php5.89 ▲0.0079.00 ▼12.67
Media Library /wp-admin/upload.php3.23 ▲0.0032.67 ▼1.64
Easy Dash /wp-admin/admin.php?page=learndash-easy-dash3.0022.69

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 348 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Easy Dash for LearnDash
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.28 ▼0.311.62 ▼0.0436.82 ▼4.95
Dashboard /wp-admin2,195 ▲155.59 ▼0.0790.57 ▲2.9638.86 ▼1.69
Posts /wp-admin/edit.php2,100 ▼02.03 ▲0.0334.49 ▼1.2330.59 ▼8.30
Add New Post /wp-admin/post-new.php1,529 ▲323.30 ▼0.43630.91 ▼59.2951.86 ▼3.07
Media Library /wp-admin/upload.php1,400 ▼04.22 ▼0.0295.85 ▼13.4943.69 ▼7.06
Easy Dash /wp-admin/admin.php?page=learndash-easy-dash280.420.093.71

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded

Smoke tests 50% from 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 50% 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
Please fix the following
  • 10× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/easy-dash-for-learndash/admin/shortcode-sections/global.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/easy-dash-for-learndash/admin/shortcode-sections/course.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/easy-dash-for-learndash/admin/shortcode-sections/user.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/easy-dash-for-learndash/admin/tred-settings.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/easy-dash-for-learndash/admin/shortcode-sections/all.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function tred_display_content_area() in wp-content/plugins/easy-dash-for-learndash/admin/tred-dash.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/easy-dash-for-learndash/admin/shortcode-sections/global.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function tred_display_filter_section() in wp-content/plugins/easy-dash-for-learndash/admin/tred-filter.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/easy-dash-for-learndash/admin/tred-admin.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/easy-dash-for-learndash/admin/shortcode-sections/group.php:7

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
These are user-side errors you should fix
    • > GET request to /wp-admin/admin.php?page=learndash-easy-dash
    • > Network (severe)
    wp-admin/admin.php?page=learndash-easy-dash - Failed to load resource: the server responded with a status of 403 (Forbidden)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
5 plugin tags: learndash, elearning, learning, lms, education

easy-dash-for-learndash/learndash-easy-dash.php 85% from 13 tests

The entry point to "Easy Dash for LearnDash" version 2.4.1 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("easy-dash-for-learndash.php" instead of "learndash-easy-dash.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin146,515 lines of code in 268 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript13327,78044,459125,541
CSS10779657413,374
PHP175232113,966
PO File51,0701,4352,745
JSON400726
Sass2363163

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity18.33
▷ Minimum class complexity6.00
▷ Maximum class complexity37.00
Average method complexity2.62
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods32
▷ Static methods00.00%
▷ Public methods3093.75%
▷ Protected methods13.12%
▷ Private methods13.12%
Functions93
▷ Named functions6974.19%
▷ Anonymous functions2425.81%
Constants14
▷ Global constants14100.00%
▷ Class constants00.00%
▷ Public constants00.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
10 compressed PNG files occupy 0.00MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/DataTables/DataTables-1.10.25/images/sort_asc.png0.16KB0.25KB0.00%
assets/DataTables/DataTables-1.11.3/images/sort_both.png0.20KB0.29KB0.00%
assets/DataTables/DataTables-1.10.25/images/sort_desc_disabled.png0.14KB0.25KB0.00%
assets/DataTables/DataTables-1.10.25/images/sort_desc.png0.15KB0.25KB0.00%
assets/DataTables/DataTables-1.11.3/images/sort_asc.png0.16KB0.25KB0.00%