73% fitnessbliss-calculators

Code Review | fitnessbliss calculators plugin

WordPress plugin fitnessbliss calculators plugin scored73%from 54 tests.

About plugin

  • Plugin page: fitnessbliss-calc...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8-6.1.1
  • WordPress version: 6.3.1
  • First release: Dec 15, 2022
  • Latest release: Dec 23, 2022
  • Number of updates: 3
  • Update frequency: every 7.0 days
  • Top authors: fstn (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /236 total downloads

Benchmarks

Plugin footprint 65% 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.89MB] [CPU: ▼30.59ms] Passed 4 tests

An overview of server-side resources used by fitnessbliss calculators plugin
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.45 ▼0.0224.48 ▼12.71
Dashboard /wp-admin3.06 ▼0.2522.59 ▼21.56
Posts /wp-admin/edit.php3.06 ▼0.3025.78 ▼22.11
Add New Post /wp-admin/post-new.php3.06 ▼2.8325.45 ▼65.96
Media Library /wp-admin/upload.php3.06 ▼0.1722.08 ▼11.93

Server storage [IO: ▲0.75MB] [DB: ▲0.07MB] Passed 3 tests

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 21 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by fitnessbliss calculators plugin
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,573 ▲81213.77 ▼0.8812.49 ▲10.9141.65 ▲2.58
Dashboard /wp-admin2,207 ▲275.53 ▼0.0882.32 ▼5.8038.51 ▼3.47
Posts /wp-admin/edit.php2,112 ▲121.95 ▼0.0538.89 ▲1.8335.39 ▲0.77
Add New Post /wp-admin/post-new.php1,545 ▲1718.11 ▼5.01616.22 ▼57.6274.44 ▲21.75
Media Library /wp-admin/upload.php1,412 ▲124.22 ▼0.0192.17 ▼4.9944.67 ▼0.59

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin did not uninstall without warnings or errors
    • > Warning in wp-includes/class-wp-hook.php+310
    call_user_func_array() expects parameter 1 to be a valid callback, class 'FitnessBlissSettings' does not have a method 'fitnessbliss_admin_menu'
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however 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
Almost there! Just fix the following items
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/fitnessbliss-calculators/includes/class-short-code.php:214
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/fitnessbliss-calculators/includes/js_css_register.php:30

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need your attention:
  • Donate link: Invalid URI found ("")
  • Screenshots: Please add images for these screenshots: #1 (includes/screenshots/water-small.png.), #2 (includes/screenshots/bmi-small.png.), #3 (includes/screenshots/fat-small.png.), #4 (includes/screenshots/protein-small.png.)
You can look at the official readme.txt

fitnessbliss-calculators/fitness-calculators-plugin.php 85% from 13 tests

This is the main PHP file of "fitnessbliss calculators plugin" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("fitnessbliss-calculators.php" instead of "fitness-calculators-plugin.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
Success! There were no dangerous files found in this plugin2,563 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript6146322,205
PHP56619357
CSS1061

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.14
Average class complexity5.00
▷ Minimum class complexity1.00
▷ Maximum class complexity9.00
Average method complexity1.75
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods16
▷ Static methods531.25%
▷ Public methods16100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
8 PNG files occupy 0.33MB with 0.19MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/screenshots/bfc-small.png46.35KB19.69KB▼ 57.52%
includes/screenshots/bmi-large.png22.42KB9.91KB▼ 55.81%
includes/screenshots/water-large.png47.56KB17.25KB▼ 63.73%
includes/screenshots/bmi-small.png26.58KB12.22KB▼ 54.02%
includes/screenshots/protein-small.png49.10KB23.37KB▼ 52.40%