84% real-buddha-quotes

Code Review | Real Buddha Quotes

WordPress plugin Real Buddha Quotes scored84%from 54 tests.

About plugin

  • Plugin page: real-buddha-quotes
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.2
  • WordPress version: 6.3.1
  • First release: Sep 1, 2020
  • Latest release: Apr 6, 2023
  • Number of updates: 26
  • Update frequency: every 36.4 days
  • Top authors: suttafriends (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /550 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.01MB] [CPU: ▼5.62ms] Passed 4 tests

This is a short check of server-side resources used by Real Buddha Quotes
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0143.80 ▲0.64
Dashboard /wp-admin3.33 ▼0.0253.90 ▼11.04
Posts /wp-admin/edit.php3.38 ▲0.0248.83 ▼0.47
Add New Post /wp-admin/post-new.php5.91 ▲0.0288.08 ▼11.60
Media Library /wp-admin/upload.php3.25 ▲0.0239.14 ▲3.13
Real Buddha Quotes /wp-admin/options-general.php?page=random-dhamma-verses3.2131.68

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Real Buddha Quotes
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,818 ▲7214.73 ▲0.381.98 ▲0.4842.70 ▲1.30
Dashboard /wp-admin2,196 ▲185.58 ▼0.1587.12 ▼25.0238.05 ▼5.42
Posts /wp-admin/edit.php2,104 ▲41.96 ▼0.0534.52 ▼4.9334.17 ▼1.86
Add New Post /wp-admin/post-new.php1,531 ▲523.05 ▲0.13668.79 ▲19.5156.52 ▲6.60
Media Library /wp-admin/upload.php1,404 ▲74.18 ▼0.0495.67 ▼2.0944.98 ▲0.49
Real Buddha Quotes /wp-admin/options-general.php?page=random-dhamma-verses8812.1229.0433.35

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 7 options in the database
    • widget_rdhp_widget
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/real-buddha-quotes/real-buddha-quotes.php:466

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
6 plugin tags: quotations, buddha, buddhism, dhamma, quote...

real-buddha-quotes/real-buddha-quotes.php Passed 13 tests

"Real Buddha Quotes" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
43 characters long description:
Displays a random verse from the Dhammapada

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Success! There were no dangerous files found in this plugin602 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP15946602

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.17
Average class complexity4.50
▷ Minimum class complexity4.00
▷ Maximum class complexity5.00
Average method complexity1.64
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods11
▷ Static methods00.00%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin