84% wp-tipbot

Code Review | WP-TipBot

WordPress plugin WP-TipBot scored 84% from 54 tests.

About plugin

  • Plugin page: wp-tipbot
  • Plugin version: 1.1.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.0.0
  • WordPress version: 6.3.1
  • First release: Nov 26, 2018
  • Latest release: Dec 11, 2018
  • Number of updates: 10
  • Update frequency: every 1.6 days
  • Top authors: alordiel (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 666 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼4.41ms] Passed 4 tests

This is a short check of server-side resources used by WP-TipBot
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0839.27 ▼1.93
Dashboard /wp-admin3.38 ▲0.0848.27 ▲3.49
Posts /wp-admin/edit.php3.43 ▲0.0845.64 ▲1.43
Add New Post /wp-admin/post-new.php5.96 ▲0.0884.10 ▼14.31
Media Library /wp-admin/upload.php3.30 ▲0.0734.78 ▼2.83
WP TipBot /wp-admin/options-general.php?page=wp-tipbot3.2733.36

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for WP-TipBot
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲6914.48 ▼0.181.73 ▲0.0037.29 ▼14.91
Dashboard /wp-admin2,207 ▲225.87 ▲0.0096.27 ▼17.1236.86 ▼5.47
Posts /wp-admin/edit.php2,093 ▲42.02 ▼0.0237.55 ▲0.2532.52 ▲1.80
Add New Post /wp-admin/post-new.php1,538 ▲1823.17 ▲0.19588.46 ▼34.0355.54 ▼12.98
Media Library /wp-admin/upload.php1,389 ▲44.23 ▲0.05100.94 ▲1.1042.35 ▼22.56
WP TipBot /wp-admin/options-general.php?page=wp-tipbot1,1002.3829.0031.87

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 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
  • Zombie WordPress options were found after uninstall: 7 options
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_wp_tipbot
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments

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
Even though everything seems fine, this is not an exhaustive test

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 take a closer look at the following
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/wp-tipbot/functions/shortcode.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-tipbot/functions/settings.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/wp-tipbot/classes/class.widget.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
7 plugin tags: xrptipbot, xrp, donation button, tip, wptipbot...

wp-tipbot/wp-tipbot.php Passed 13 tests

The main PHP script in "WP-TipBot" version 1.1.1 is automatically included on every request by WordPress
57 characters long description:
Displays a XRP TIP BOT button with a widget or shortcode.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin473 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP512820386
PO File1242487

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.45
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.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
1 PNG file occupies 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/WP-TipBot-logo.png14.56KB5.62KB▼ 61.39%