78% bang-tinh-lai-suat

Code Review | Bang tinh vay

WordPress plugin Bang tinh vay scored78%from 54 tests.

About plugin

  • Plugin page: bang-tinh-lai-suat
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-5.2.3
  • WordPress version: 6.3.1
  • First release: Sep 22, 2018
  • Latest release: Sep 26, 2019
  • Number of updates: 7
  • Update frequency: every 52.7 days
  • Top authors: hanhdo205 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /4,981 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼11.15ms] Passed 4 tests

A check of server-side resources used by Bang tinh vay
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0240.88 ▼6.79
Dashboard /wp-admin3.32 ▼0.0251.44 ▼13.35
Posts /wp-admin/edit.php3.37 ▲0.0246.32 ▼3.44
Add New Post /wp-admin/post-new.php5.90 ▲0.0284.10 ▼21.03
Media Library /wp-admin/upload.php3.24 ▲0.0241.14 ▲6.57
Laisuat Options /wp-admin/options-general.php?page=laisuat_options3.1930.07

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Bang tinh vay
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,879 ▲9313.46 ▼0.748.47 ▲6.3643.69 ▼7.01
Dashboard /wp-admin2,199 ▲225.66 ▲0.0497.16 ▲8.1842.50 ▲6.81
Posts /wp-admin/edit.php2,104 ▲42.00 ▼0.0233.81 ▼8.4834.38 ▼1.84
Add New Post /wp-admin/post-new.php1,531 ▲322.92 ▼0.09651.83 ▲22.1065.04 ▲16.24
Media Library /wp-admin/upload.php1,404 ▲44.16 ▼0.12100.98 ▼7.3547.62 ▼0.71
Laisuat Options /wp-admin/options-general.php?page=laisuat_options7992.0331.2658.46

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
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=laisuat_options
    • > Notice in wp-content/plugins/bang-tinh-lai-suat/laisuat.php+55
    Trying to access array offset on value of type bool

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
Please take a closer look at the following
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/bang-tinh-lai-suat/form.php:70
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/bang-tinh-lai-suat/form.php:70

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need to be fixed: The official readme.txt is a good inspiration

bang-tinh-lai-suat/laisuat.php 92% from 13 tests

"Bang tinh vay" version 1.0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("bang-tinh-lai-suat.php" instead of "laisuat.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 plugin209 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP21312111
JavaScript1251068
PO File1193427
CSS1003

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.04
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%
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
No PNG images were found in this plugin