90% tp-travel-package

Code Review | TP Travel Package

WordPress plugin TP Travel Package scored90%from 54 tests.

About plugin

  • Plugin page: tp-travel-package
  • Plugin version: 1.0.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.0
  • WordPress version: 6.3.1
  • First release: Aug 15, 2017
  • Latest release: Aug 15, 2022
  • Number of updates: 23
  • Update frequency: every 79.5 days
  • Top authors: themepalace (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,884 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
Install script ran successfully

Server metrics [RAM: ▲0.21MB] [CPU: ▼2.95ms] Passed 4 tests

Analyzing server-side resources used by TP Travel Package
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.68 ▲0.2139.62 ▼2.83
Dashboard /wp-admin3.51 ▲0.2050.89 ▲1.50
Posts /wp-admin/edit.php3.62 ▲0.2652.50 ▲3.50
Add New Post /wp-admin/post-new.php6.11 ▲0.2298.16 ▼12.47
Media Library /wp-admin/upload.php3.43 ▲0.2038.57 ▲1.99
All Destination /wp-admin/edit.php?post_type=tp-destination3.4739.20
Package Category /wp-admin/edit-tags.php?taxonomy=tp-package-category&post_type=tp-package3.4242.06
All Package /wp-admin/edit.php?post_type=tp-package3.4739.21
Add New /wp-admin/post-new.php?post_type=tp-package3.6553.37
Add New /wp-admin/post-new.php?post_type=tp-destination3.5854.81

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

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

Browser metrics Passed 4 tests

A check of browser resources used by TP Travel Package
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,857 ▲9614.67 ▲0.321.57 ▼0.0842.03 ▼4.02
Dashboard /wp-admin2,255 ▲755.63 ▼0.0487.73 ▲0.4042.62 ▲2.49
Posts /wp-admin/edit.php2,160 ▲601.98 ▼0.0135.67 ▼6.2134.00 ▼6.44
Add New Post /wp-admin/post-new.php1,586 ▲5823.34 ▲0.08668.47 ▼8.6655.86 ▼8.84
Media Library /wp-admin/upload.php1,460 ▲634.23 ▲0.01109.14 ▼11.3049.76 ▼1.96
All Destination /wp-admin/edit.php?post_type=tp-destination1,1751.9729.8431.05
Package Category /wp-admin/edit-tags.php?taxonomy=tp-package-category&post_type=tp-package1,3342.1227.7235.36
All Package /wp-admin/edit.php?post_type=tp-package1,1831.9433.3431.63
Add New /wp-admin/post-new.php?post_type=tp-package2,8167.82186.8560.22
Add New /wp-admin/post-new.php?post_type=tp-destination2,6527.75179.1158.42

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 97% 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
Please fix the following attributes:
  • Screenshots: These screenshots require images: #1 (Package Meta Fields), #2 (Destination Meta Fields)
The official readme.txt might help

tp-travel-package/tp-travel-package.php Passed 13 tests

"TP Travel Package" version 1.0.4's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
97 characters long description:
This Plugin has assembled destination and packages and its elementary fields for travel websites.

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
Good job! No executable or dangerous file extensions detected2,481 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
CSS637391,625
PHP6164163727
SVG303125
JavaScript2004

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity21.40
▷ Minimum class complexity1.00
▷ Maximum class complexity48.00
Average method complexity5.25
▷ Minimum method complexity1.00
▷ Maximum method complexity34.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes120.00%
Methods24
▷ Static methods28.33%
▷ Public methods24100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin