83% parcel-tracker-ecourier

Code Review | Parcel Tracker eCourier

WordPress plugin Parcel Tracker eCourier scored83%from 54 tests.

About plugin

  • Plugin page: parcel-tracker-ec...
  • Plugin version: 1.0.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.7
  • WordPress version: 6.3.1
  • First release: Apr 19, 2021
  • Latest release: May 5, 2021
  • Number of updates: 16
  • Update frequency: every 1.0 days
  • Top authors: simongomes02 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /496 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.29MB] [CPU: ▼0.23ms] Passed 4 tests

A check of server-side resources used by Parcel Tracker eCourier
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.78 ▲0.3243.14 ▼0.16
Dashboard /wp-admin3.63 ▲0.3250.88 ▼3.50
Posts /wp-admin/edit.php3.68 ▲0.3255.02 ▲1.97
Add New Post /wp-admin/post-new.php6.15 ▲0.2690.91 ▲0.78
Media Library /wp-admin/upload.php3.49 ▲0.2642.50 ▲4.94

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 47 new files
Database: 1 new table, 8 new options
New tables
ept_settings
New WordPress options
can_compress_scripts
ept_installed
ept_version
widget_recent-posts
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Parcel Tracker eCourier
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲4214.25 ▼0.101.64 ▼0.2841.67 ▼4.42
Dashboard /wp-admin2,222 ▲425.57 ▼0.1089.80 ▲1.4087.70 ▲42.74
Posts /wp-admin/edit.php2,146 ▲462.10 ▲0.1237.12 ▼0.7533.48 ▼1.81
Add New Post /wp-admin/post-new.php1,578 ▲5223.04 ▼0.35720.75 ▲36.3664.63 ▲4.94
Media Library /wp-admin/upload.php1,442 ▲424.20 ▼0.00100.03 ▼13.3364.21 ▲15.08

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/parcel-tracker-ecourier/includes/Admin/views/settings-view.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/parcel-tracker-ecourier/includes/Frontend/views/form-parcel-tracker.php:11

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: These screenshots lack descriptions #1, #2, #3, #4 in parcel-tracker-ecourier/assets to your readme.txt
  • Tags: There are too many tags (12 tag instead of maximum 10)
You can take inspiration from this readme.txt

parcel-tracker-ecourier/parcel-tracker-ecourier.php 77% from 13 tests

The entry point to "Parcel Tracker eCourier" version 1.0.2 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Domain Path: The domain path is invalid: folder "/languages" does not exist
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Git Repository: Please remove the Git repository from this plugin

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin13,753 lines of code in 39 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript31,81910,49010,619
PHP307201,0692,502
CSS14910351
Markdown1660181
JSON30099
SVG1001

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity15.50
▷ Minimum class complexity1.00
▷ Maximum class complexity68.00
Average method complexity2.76
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces6
Interfaces0
Traits0
Classes18
▷ Abstract classes00.00%
▷ Concrete classes18100.00%
▷ Final classes15.56%
Methods149
▷ Static methods1610.74%
▷ Public methods11073.83%
▷ Protected methods64.03%
▷ Private methods3322.15%
Functions6
▷ Named functions583.33%
▷ Anonymous functions116.67%
Constants11
▷ Global constants981.82%
▷ Class constants218.18%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
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
assets/images/menu_icon.png2.13KB1.06KB▼ 50.18%