84% tutormate

Code Review | TutorMate

WordPress plugin TutorMate scored84%from 54 tests.

About plugin

  • Plugin page: tutormate
  • Plugin version: 1.0.5
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3-6.3
  • WordPress version: 6.3.1
  • First release: Jun 22, 2021
  • Latest release: Aug 17, 2023
  • Number of updates: 8
  • Update frequency: every 98.4 days
  • Top authors: themeum (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10,000+ active /72,258 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 successfully, without throwing any errors or notices

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

Server-side resources used by TutorMate
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0144.29 ▲7.90
Dashboard /wp-admin3.32 ▼0.0342.11 ▼20.26
Posts /wp-admin/edit.php3.37 ▲0.0146.84 ▲0.32
Add New Post /wp-admin/post-new.php5.90 ▲0.0187.61 ▼12.64
Media Library /wp-admin/upload.php3.24 ▲0.0135.79 ▲1.77

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 40 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for TutorMate
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.23 ▼0.061.64 ▼0.0338.35 ▼3.45
Dashboard /wp-admin2,195 ▲155.50 ▼0.1480.64 ▼3.8738.24 ▼0.61
Posts /wp-admin/edit.php2,100 ▼01.97 ▼0.0640.60 ▲2.7634.75 ▼1.41
Add New Post /wp-admin/post-new.php1,526 ▼923.09 ▼0.25644.34 ▼10.7049.29 ▼8.04
Media Library /wp-admin/upload.php1,397 ▼34.19 ▲0.0198.85 ▼9.2741.94 ▼6.52

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options

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)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'AwesomeMotive\\WPContentImporter2\\WXRImporter' not found in wp-content/plugins/tutormate/lib/awesomemotive/src/Importer.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'AwesomeMotive\\WPContentImporter2\\WPImporterLogger' not found in wp-content/plugins/tutormate/lib/awesomemotive/src/WPImporterLoggerCLI.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Importer' not found in wp-content/plugins/tutormate/lib/awesomemotive/src/WXRImporter.php:7

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 Passed 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: import, content, demo, data

tutormate/tutormate.php Passed 13 tests

The entry point to "TutorMate" version 1.0.5 is a PHP file that has certain tags in its header comment area
54 characters long description:
Companion demo importer plugin for TutorStarter theme.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin5,211 lines of code in 31 files:
LanguageFilesBlank linesComment linesLines of code
PHP281,1852,2884,259
CSS21742951
JavaScript1011

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity30.65
▷ Minimum class complexity1.00
▷ Maximum class complexity290.00
Average method complexity4.23
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes23
▷ Abstract classes00.00%
▷ Concrete classes23100.00%
▷ Final classes14.35%
Methods213
▷ Static methods3918.31%
▷ Public methods14769.01%
▷ Protected methods3918.31%
▷ Private methods2712.68%
Functions4
▷ Named functions125.00%
▷ Anonymous functions375.00%
Constants5
▷ Global constants360.00%
▷ Class constants240.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
6 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/logo@2x.png5.22KB2.45KB▼ 53.20%
assets/images/qubely.png0.95KB0.84KB▼ 11.83%
assets/images/qubely-not-used.png0.85KB1.06KB0.00%
assets/images/elementor.png0.16KB0.18KB0.00%
assets/images/tutor-starter-logo.png2.71KB1.43KB▼ 47.23%