94% badgeos-buddypress-notifier

Code Review | BadgeOS BuddyPress Notifier

WordPress plugin BadgeOS BuddyPress Notifier scored 94% from 54 tests.

About plugin

  • Plugin page: badgeos-buddypres...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4.2-3.9.1
  • WordPress version: 5.8.1
  • First release: Jul 14, 2014
  • Latest release: Jul 14, 2014
  • Number of updates: 4
  • Update frequency: every 1.0 days
  • Top authors: rikkouri (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 2,094 total downloads


Plugin footprint Passed 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.00MB] [CPU: ▼142.59ms] Passed 4 tests

This is a short check of server-side resources used by BadgeOS BuddyPress Notifier
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.0131.78 ▼1.56
Dashboard /wp-admin3.07 ▲0.0147.02 ▲0.71
Posts /wp-admin/edit.php3.12 ▲0.0142.30 ▼1.29
Add New Post /wp-admin/post-new.php5.42 ▼0.0190.73 ▼568.21
Media Library /wp-admin/upload.php3.01 ▲0.0133.73 ▲1.95

Server storage [IO: ▲0.02MB] [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: 4 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for BadgeOS BuddyPress Notifier
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,703 ▲9715.89 ▼0.029.63 ▼0.2151.10 ▲2.76
Dashboard /wp-admin2,970 ▲395.97 ▼0.05144.02 ▼26.88110.59 ▲0.55
Posts /wp-admin/edit.php2,739 ▼02.83 ▲0.1268.30 ▼1.1790.93 ▼10.21
Add New Post /wp-admin/post-new.php1,615 ▲11721.44 ▲2.59269.27 ▼121.71103.19 ▼6.91
Media Library /wp-admin/upload.php1,810 ▼05.05 ▼0.02148.68 ▲0.50109.73 ▼9.15

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
This plugin's uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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
Please fix the following
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'BP_Component' not found in wp-content/plugins/badgeos-buddypress-notifier/includes/notifier.php:6
    • > PHP Notice
      Undefined variable: plugin in wp-content/plugins/badgeos-buddypress-notifier/loader.php on line 16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/badgeos-buddypress-notifier/loader.php:34

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test


Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
2 plugin tags: badgeos, buddypress

badgeos-buddypress-notifier/loader.php 92% from 13 tests

Analyzing the main PHP file in "BadgeOS BuddyPress Notifier" version 1.0
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("badgeos-buddypress-notifier.php" instead of "loader.php")

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
Everything looks great! No dangerous files found in this plugin83 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity1.80
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods120.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions3100.00%
▷ Anonymous functions00.00%
▷ Global constants2100.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
There are no PNG files in this plugin