89% bp-favorite-notifications

Code Review | Bp Favorite Notifications

WordPress plugin Bp Favorite Notifications scored89%from 54 tests.

About plugin

  • Plugin page: bp-favorite-notif...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.0
  • WordPress version: 6.3.1
  • First release: Dec 11, 2014
  • Latest release: Dec 11, 2014
  • Number of updates: 5
  • Update frequency: every 2.8 days
  • Top authors: aghajoon (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,723 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼0.72ms] Passed 4 tests

Server-side resources used by Bp Favorite Notifications
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0538.23 ▲1.93
Dashboard /wp-admin3.35 ▲0.0054.68 ▼3.34
Posts /wp-admin/edit.php3.40 ▲0.0445.85 ▲1.94
Add New Post /wp-admin/post-new.php5.95 ▲0.0686.76 ▼2.66
Media Library /wp-admin/upload.php3.27 ▲0.0435.77 ▲1.17

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Bp Favorite Notifications
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,876 ▲10513.36 ▼1.167.99 ▲6.2743.33 ▲2.06
Dashboard /wp-admin2,199 ▲255.68 ▲0.1082.55 ▼7.5035.71 ▼7.20
Posts /wp-admin/edit.php2,086 ▼142.03 ▲0.0234.03 ▼0.3134.49 ▼2.55
Add New Post /wp-admin/post-new.php1,532 ▲623.59 ▲0.13675.84 ▲5.3153.16 ▼1.33
Media Library /wp-admin/upload.php1,407 ▲74.15 ▼0.0496.97 ▲1.6243.54 ▲0.24

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests Passed 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 Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Screenshots: These screenshots do not have images: #1 (mark as favorite), #2 (mark as favorite)
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === bp-favorite-notifications === )
The official readme.txt might help

bp-favorite-notifications/bp-favorite.php 92% from 13 tests

The primary PHP file in "Bp Favorite Notifications" version 1.0 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("bp-favorite-notifications.php" instead of "bp-favorite.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected332 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP12911154
CSS2320138
PO File181626
JavaScript11014

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.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
2 PNG files occupy 0.06MB with 0.04MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png26.80KB10.00KB▼ 62.69%
screenshot-2.png37.96KB14.71KB▼ 61.24%