89% responsive-bmi-calculator

Code Review | Responsive BMI Calculator

WordPress plugin Responsive BMI Calculator scored 89% from 54 tests.

About plugin

  • Plugin page: responsive-bmi-ca...
  • Plugin version: 2.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 2.7-5.5
  • WordPress version: 6.3.1
  • First release: Sep 10, 2018
  • Latest release: Jan 22, 2021
  • Number of updates: 41
  • Update frequency: every 21.2 days
  • Top authors: guelben (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active / 2,365 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▼0.54ms] Passed 4 tests

An overview of server-side resources used by Responsive BMI Calculator
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0836.10 ▼5.70
Dashboard /wp-admin3.37 ▲0.0649.83 ▼0.34
Posts /wp-admin/edit.php3.42 ▲0.0650.71 ▲5.81
Add New Post /wp-admin/post-new.php5.95 ▲0.0695.33 ▲2.62
Media Library /wp-admin/upload.php3.29 ▲0.0636.04 ▲1.25
BMI Calculator /wp-admin/options-general.php?page=responsive-bmi-calculator/responsive-bmi-calculator.php3.2532.90

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 16 new files
Database: no new tables, 16 new options
New WordPress options
pageId_RBMIC
widget_rbmic
texto_RBMIC
widget_recent-comments
widget_theysaidso_widget
db_upgraded
texto_boton__RBMIC
widget_recent-posts
colorBorde_RBMIC
boton1_RBMIC
...

Browser metrics Passed 4 tests

Responsive BMI Calculator: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,809 ▲6314.44 ▼0.151.59 ▼0.2639.64 ▼5.54
Dashboard /wp-admin2,210 ▲364.84 ▼0.03109.47 ▼17.9342.01 ▲0.98
Posts /wp-admin/edit.php2,093 ▲42.03 ▲0.0241.68 ▲5.9935.92 ▲4.26
Add New Post /wp-admin/post-new.php1,536 ▲2223.01 ▲5.33589.28 ▼103.3653.32 ▲1.38
Media Library /wp-admin/upload.php1,395 ▲134.18 ▲0.0194.41 ▲0.3541.23 ▼4.93
BMI Calculator /wp-admin/options-general.php?page=responsive-bmi-calculator/responsive-bmi-calculator.php8482.0326.9226.62

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 did not uninstall successfully, leaving 8 options in the database
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • texto_RBMIC
    • widget_rbmic
    • widget_recent-posts
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 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
4 plugin tags: bmi calculator, calculator, health, bmi

responsive-bmi-calculator/responsive-bmi-calculator.php 85% from 13 tests

The primary PHP file in "Responsive BMI Calculator" version 2.0 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Text Domain: The text domain should only use lowercase characters and dashes
  • Description: Keep the plugin description shorter than 140 characters (currently 302 characters long)

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
No dangerous file extensions were detected667 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP93953425
PO File14546145
CSS13097

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions10
▷ Named functions10100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/calcular.png2.33KB1.78KB▼ 23.47%