84% badgeos-tutorlms

Code Review | BadgeOS Tutor LMS Add-on

WordPress plugin BadgeOS Tutor LMS Add-on scored84%from 54 tests.

About plugin

  • Plugin page: badgeos-tutorlms
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Sep 7, 2020
  • Latest release: Feb 25, 2022
  • Number of updates: 8
  • Update frequency: every 67.8 days
  • Top authors: learningtimes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /2,248 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

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

A check of server-side resources used by BadgeOS Tutor LMS Add-on
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0040.66 ▼3.60
Dashboard /wp-admin3.31 ▲0.0046.74 ▼6.24
Posts /wp-admin/edit.php3.36 ▲0.0046.65 ▼2.16
Add New Post /wp-admin/post-new.php5.89 ▲0.0085.11 ▼11.05
Media Library /wp-admin/upload.php3.23 ▲0.0035.44 ▼3.17

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for BadgeOS Tutor LMS Add-on
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲3914.42 ▲0.271.67 ▼0.0644.03 ▲0.48
Dashboard /wp-admin2,195 ▲245.63 ▼0.0398.18 ▼5.0944.01 ▼3.66
Posts /wp-admin/edit.php2,100 ▼01.95 ▼0.0834.24 ▼7.7233.73 ▼5.42
Add New Post /wp-admin/post-new.php1,526 ▼223.48 ▲0.29671.57 ▼10.4070.04 ▲16.24
Media Library /wp-admin/upload.php1,400 ▲34.18 ▼0.1396.84 ▼6.0044.01 ▼0.75

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following items
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/badgeos-tutorlms/includes/steps-ui.php:30
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/badgeos-tutorlms/badgeos-tutorlms.php:75
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/badgeos-tutorlms/includes/rules-engine.php:42

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need to be fixed:
  • Requires at least: Invalid version format
  • Tags: There are too many tags (18 tag instead of maximum 10)
The official readme.txt might help

badgeos-tutorlms/badgeos-tutorlms.php Passed 13 tests

This is the main PHP file of "BadgeOS Tutor LMS Add-on" version 1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
61 characters long description:
This BadgeOS add-on integrates BadgeOS features with TutorLMS

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin1,620 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP33716571,514
PO File13838105
Markdown1101

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.54
Average class complexity20.00
▷ Minimum class complexity20.00
▷ Maximum class complexity20.00
Average method complexity4.17
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods116.67%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions16
▷ Named functions16100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin