84% widget-xrptipbot

Code Review | XRPTIPBOT Widget by HBENSLAMA

WordPress plugin XRPTIPBOT Widget by HBENSLAMA scored84%from 54 tests.

About plugin

  • Plugin page: widget-xrptipbot
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-4.9
  • WordPress version: 6.3.1
  • First release: Nov 11, 2018
  • Latest release: Nov 11, 2018
  • Number of updates: 6
  • Update frequency: N/A
  • Top authors: houssembenslama (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /502 total downloads

Benchmarks

Plugin footprint 83% from 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.02MB] [CPU: ▼12.40ms] Passed 4 tests

An overview of server-side resources used by XRPTIPBOT Widget by HBENSLAMA
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0347.76 ▲8.50
Dashboard /wp-admin3.33 ▼0.0150.60 ▼17.39
Posts /wp-admin/edit.php3.38 ▲0.0346.46 ▼11.86
Add New Post /wp-admin/post-new.php5.91 ▲0.0385.17 ▼17.95
Media Library /wp-admin/upload.php3.26 ▲0.0337.06 ▼2.38

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
db_upgraded
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
widget_xrptipbot_widget

Browser metrics Passed 4 tests

A check of browser resources used by XRPTIPBOT Widget by HBENSLAMA
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲6814.28 ▼0.071.91 ▲0.1747.25 ▲3.38
Dashboard /wp-admin2,192 ▲155.62 ▼0.0587.45 ▼0.1140.42 ▼8.35
Posts /wp-admin/edit.php2,100 ▼01.96 ▼0.0037.55 ▼2.5034.34 ▼5.74
Add New Post /wp-admin/post-new.php1,528 ▲223.43 ▲0.46684.14 ▼3.8345.72 ▼12.47
Media Library /wp-admin/upload.php1,400 ▼04.31 ▲0.19106.19 ▼7.4151.43 ▲2.46

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
The following items require your attention
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_xrptipbot_widget
    • db_upgraded
    • widget_theysaidso_widget

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 no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/widget-xrptipbot/xrptipbot-widget.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/widget-xrptipbot/class.xrptipbot-widget.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 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: xrptipbot, xrp, micro-payments, interledger, web-monetized...

widget-xrptipbot/xrptipbot-widget.php 92% from 13 tests

The main PHP script in "XRPTIPBOT Widget by HBENSLAMA" version 1.0.2 is automatically included on every request by WordPress
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("widget-xrptipbot.php" instead of "xrptipbot-widget.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin86 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2153986

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.04
Average class complexity3.00
▷ Minimum class complexity3.00
▷ Maximum class complexity3.00
Average method complexity1.50
▷ Minimum method complexity1.00
▷ Maximum method complexity2.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%
Functions1
▷ Named functions1100.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
3 PNG files occupy 0.13MB with 0.09MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png24.41KB6.65KB▼ 72.76%
screenshot-1.png28.88KB7.79KB▼ 73.04%
screenshot-3.png76.15KB21.28KB▼ 72.05%