83% learnpress-course-review

Code Review | LearnPress - Course Review

WordPress plugin LearnPress - Course Review scored83%from 54 tests.

About plugin

  • Plugin page: learnpress-course...
  • Plugin version: 4.0.8
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8-6.1.1
  • WordPress version: 6.3.1
  • First release: Jun 16, 2015
  • Latest release: May 3, 2023
  • Number of updates: 56
  • Update frequency: every 51.4 days
  • Top authors: ThimPress (55.36%)thongta (17.86%)tunnhn (16.07%)leehld (12.5%)phamtungpth (3.57%)

Code review

54 tests

User reviews

6 reviews

Install metrics

40,000+ active /830,590 total downloads


Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

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

An overview of server-side resources used by LearnPress - Course Review
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0041.20 ▼0.18
Dashboard /wp-admin3.31 ▲0.0051.70 ▼2.92
Posts /wp-admin/edit.php3.36 ▲0.0046.91 ▼8.67
Add New Post /wp-admin/post-new.php5.89 ▲0.0087.58 ▼10.43
Media Library /wp-admin/upload.php3.23 ▲0.0038.12 ▼0.54

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

An overview of browser requirements for LearnPress - Course Review
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.44 ▼0.191.95 ▲0.1547.17 ▲1.62
Dashboard /wp-admin2,195 ▲155.61 ▼0.0693.77 ▲6.0039.52 ▼0.12
Posts /wp-admin/edit.php2,100 ▼02.01 ▼0.0935.01 ▼5.7034.54 ▼3.55
Add New Post /wp-admin/post-new.php1,526 ▼223.18 ▲0.18647.53 ▼50.2554.07 ▼8.39
Media Library /wp-admin/upload.php1,394 ▼04.36 ▲0.1599.49 ▼6.4543.24 ▼1.31

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

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 'LP_Abstract_REST_Controller' not found in wp-content/plugins/learnpress-course-review/inc/rest-api/class-lp-rest-courses-reviews-controller.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/learnpress-course-review/inc/rest-api/class-rest-api.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function LP_Addon_Course_Review\\add_action() in wp-content/plugins/learnpress-course-review/inc/template-hooks/list-rating-reviews.php:28

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side


Plugin configuration 90% from 29 tests

readme.txt 81% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
  • Tags: Too many tags (13 tag instead of maximum 10); only the first 5 tags are used in your directory listing
  • Screenshots: Please add an image for screenshot #1 (LearnPress Course Review screenshot.)
  • Donate link: Invalid URI found ("")
You can look at the official readme.txt

learnpress-course-review/learnpress-course-review.php Passed 13 tests

"LearnPress - Course Review" version 4.0.8's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
25 characters long description:
Adding review for course.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin2,216 lines of code in 23 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity12.78
▷ Minimum class complexity2.00
▷ Maximum class complexity34.00
Average method complexity2.96
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes00.00%
▷ Static methods59.26%
▷ Public methods4481.48%
▷ Protected methods1018.52%
▷ Private methods00.00%
▷ Named functions1285.71%
▷ Anonymous functions214.29%
▷ Global constants787.50%
▷ Class constants112.50%
▷ Public constants1100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/star-rating-sprite.png1.96KB0.87KB▼ 55.43%