83% mini-course-generator

Code Review | Mini Course Generator | Embed mini-courses and interactive content

WordPress plugin Mini Course Generator | Embed mini-courses and interactive content scored83%from 54 tests.

About plugin

  • Plugin page: mini-course-gener...
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.0.1
  • WordPress version: 6.3.1
  • First release: Jul 20, 2022
  • Latest release: Dec 22, 2022
  • Number of updates: 22
  • Update frequency: every 7.5 days
  • Top authors: minicoursegenerator (100%)

Code review

54 tests

User reviews

1 review

Install metrics

90+ active /1,815 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.07MB] [CPU: ▼0.85ms] Passed 4 tests

This is a short check of server-side resources used by Mini Course Generator | Embed mini-courses and interactive content
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0743.00 ▲2.82
Dashboard /wp-admin3.36 ▲0.0645.34 ▼3.52
Posts /wp-admin/edit.php3.48 ▲0.1245.37 ▲1.10
Add New Post /wp-admin/post-new.php5.96 ▲0.0883.46 ▼3.79
Media Library /wp-admin/upload.php3.29 ▲0.0643.07 ▲7.94

Server storage [IO: ▲0.38MB] [DB: ▲0.07MB] Passed 3 tests

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 28 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
can_compress_scripts
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Mini Course Generator | Embed mini-courses and interactive content
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,915 ▲15413.39 ▼1.238.86 ▲7.2039.74 ▼1.24
Dashboard /wp-admin2,214 ▲375.64 ▲0.0794.36 ▲3.1542.06 ▼2.35
Posts /wp-admin/edit.php2,116 ▲192.00 ▲0.0438.94 ▲2.3429.88 ▼3.83
Add New Post /wp-admin/post-new.php1,703 ▲17725.07 ▲1.89600.20 ▼79.0652.59 ▼10.34
Media Library /wp-admin/upload.php1,485 ▲884.21 ▲0.0597.74 ▼0.1741.96 ▼3.11

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

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

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 everything seems fine, this is not an exhaustive test

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 take a closer look at the following
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/mini-course-generator/admin/partials/mcg-admin-display.php
    • > /wp-content/plugins/mini-course-generator/public/partials/mcg-public-display.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need to be fixed:
  • Donate link: Invalid URI found ("-")
  • Screenshots: Add an image for screenshot #1 (Engaging experience for your audience.)
Please take inspiration from this readme.txt

mini-course-generator/mcg.php 85% from 13 tests

This is the main PHP file of "Mini Course Generator | Embed mini-courses and interactive content" version 1.0.2, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("mini-course-generator.php" instead of "mcg.php")

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
Everything looks great! No dangerous files found in this plugin486 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
PHP17150551273
JavaScript24839160
CSS292653

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.08
Average class complexity1.57
▷ Minimum class complexity1.00
▷ Maximum class complexity4.00
Average method complexity1.15
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods26
▷ Static methods27.69%
▷ Public methods2076.92%
▷ Protected methods00.00%
▷ Private methods623.08%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.07MB with 0.04MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/images/logo.png49.63KB23.05KB▼ 53.56%
admin/images/love-wp.png23.39KB12.04KB▼ 48.52%