84% bp-user-reviews

Code Review | BP Member Reviews

WordPress plugin BP Member Reviews scored84%from 54 tests.

About plugin

  • Plugin page: bp-user-reviews
  • Plugin version: 1.2.6
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.9.5
  • WordPress version: 6.3.1
  • First release: Sep 29, 2016
  • Latest release: May 11, 2018
  • Number of updates: 58
  • Update frequency: every 10.2 days
  • Top authors: wordplus (87.93%)sooskriszta (13.79%)

Code review

54 tests

User reviews

12 reviews

Install metrics

50+ active /5,591 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.12MB] [CPU: ▼2.52ms] Passed 4 tests

Analyzing server-side resources used by BP Member Reviews
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.1244.20 ▲6.69
Dashboard /wp-admin3.43 ▲0.1246.45 ▼4.18
Posts /wp-admin/edit.php3.54 ▲0.1845.34 ▼3.44
Add New Post /wp-admin/post-new.php6.01 ▲0.1282.08 ▼6.71
Media Library /wp-admin/upload.php3.35 ▲0.1236.09 ▲4.24

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 27 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for BP Member Reviews
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.22 ▼1.081.61 ▼0.2742.69 ▼0.02
Dashboard /wp-admin2,200 ▲125.81 ▲0.90102.99 ▼11.9638.29 ▼0.57
Posts /wp-admin/edit.php2,089 ▼02.03 ▲0.0337.18 ▼4.2431.99 ▼4.85
Add New Post /wp-admin/post-new.php1,538 ▲1923.18 ▼0.11660.20 ▼14.1852.55 ▼1.64
Media Library /wp-admin/upload.php1,391 ▲34.25 ▲0.0299.92 ▼1.7843.78 ▼2.56

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
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • 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)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 6× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/bp-user-reviews/templates/edit.php:3
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/bp-user-reviews/templates/rating.php:6
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/bp-user-reviews/templates/rating.php on line 4
    • > PHP Notice
      Undefined variable: rating in wp-content/plugins/bp-user-reviews/templates/rating.php on line 4
    • > PHP Notice
      Undefined variable: rating in wp-content/plugins/bp-user-reviews/templates/rating.php on line 2
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/bp-user-reviews/templates/rating.php on line 2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that need to be fixed:
  • Plugin Name: You should set the name of your plugin on the first line ( === bp-user-reviews === )
  • Tags: You are using too many tags: 11 tag instead of maximum 10
Please take inspiration from this readme.txt

bp-user-reviews/bp-user-reviews.php Passed 13 tests

The entry point to "BP Member Reviews" version 1.2.6 is a PHP file that has certain tags in its header comment area
59 characters long description:
BuddyPress plugin to enable reviews and ratings of members.

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
Good job! No executable or dangerous file extensions detected2,423 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP61561031,012
SVG100685
PO File4181180430
CSS3225226
JavaScript213170

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity109.00
▷ Minimum class complexity109.00
▷ Maximum class complexity109.00
Average method complexity3.51
▷ Minimum method complexity1.00
▷ Maximum method complexity31.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods43
▷ Static methods613.95%
▷ Public methods43100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
PNG images were not found in this plugin