83% gps-tracking-roi-calculator

Code Review | GPS Tracking ROI

WordPress plugin GPS Tracking ROI scored83%from 54 tests.

About plugin

  • Plugin page: gps-tracking-roi-...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.6.2
  • WordPress version: 6.3.1
  • First release: Apr 5, 2021
  • Latest release: Apr 5, 2021
  • Number of updates: 2
  • Update frequency: every 5.5 days
  • Top authors: gpyestrackers (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /330 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼1.91ms] Passed 4 tests

An overview of server-side resources used by GPS Tracking ROI
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0241.88 ▲3.32
Dashboard /wp-admin3.32 ▲0.0247.57 ▼4.71
Posts /wp-admin/edit.php3.38 ▲0.0250.20 ▲5.66
Add New Post /wp-admin/post-new.php5.93 ▲0.0484.97 ▼8.02
Media Library /wp-admin/upload.php3.25 ▲0.0233.19 ▲1.76

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
db_upgraded
widget_recent-posts
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for GPS Tracking ROI
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.13 ▼1.231.74 ▼0.1342.85 ▲0.35
Dashboard /wp-admin2,206 ▲155.87 ▲0.86102.04 ▼12.2137.22 ▼8.24
Posts /wp-admin/edit.php2,089 ▼02.00 ▼0.0334.71 ▼4.6231.49 ▼1.86
Add New Post /wp-admin/post-new.php1,514 ▼1917.69 ▼5.45682.21 ▼16.5856.60 ▲1.59
Media Library /wp-admin/upload.php1,388 ▼04.21 ▼0.0196.87 ▼10.7141.68 ▼2.21

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/gps-tracking-roi-calculator/index.php:20

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Donate link: Please fix this invalid URI: ""
The official readme.txt might help

gps-tracking-roi-calculator/index.php 77% from 13 tests

The primary PHP file in "GPS Tracking ROI" version 1.0 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Domain Path: The domain path is invalid: folder "/languages" does not exist
  • Main file name: The principal plugin file should be the same as the plugin slug ("gps-tracking-roi-calculator.php" instead of "index.php")

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
There were no executable files found in this plugin352 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP14819158
JavaScript14813101
CSS15093

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.11
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin