10% ab-google-map-travel

Code Review | AB Google Map Travel (AB-MAP)

WordPress plugin AB Google Map Travel (AB-MAP) scored10%from 54 tests.

About plugin

  • Plugin page: ab-google-map-travel
  • Plugin version: 4.6
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-5.4
  • WordPress version: 6.3.1
  • First release: Jan 17, 2012
  • Latest release: Apr 3, 2020
  • Number of updates: 49
  • Update frequency: every 61.2 days
  • Top authors: abooze (100%)

Code review

54 tests

User reviews

13 reviews

Install metrics

100+ active /13,988 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
You still need to fix the following installer errors
  • Install procedure had errors
    • > User deprecated in wp-includes/functions.php+5747
    Function add_option was called with an argument that is deprecated since version 2.3.0 with no alternative available.

Server metrics [RAM: ▲0.07MB] [CPU: ▼6.73ms] Passed 4 tests

This is a short check of server-side resources used by AB Google Map Travel (AB-MAP)
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0848.81 ▲6.79
Dashboard /wp-admin3.38 ▲0.0751.42 ▼3.01
Posts /wp-admin/edit.php3.43 ▲0.0747.44 ▼5.85
Add New Post /wp-admin/post-new.php5.96 ▲0.0783.82 ▼21.68
Media Library /wp-admin/upload.php3.30 ▲0.0741.41 ▲3.61

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 17 new options
New WordPress options
can_compress_scripts
more_five_fare
less_five_fare
zoom
day_less_five_fare
theysaidso_admin_options
db_upgraded
map_width
widget_recent-comments
curr_format
...

Browser metrics Passed 4 tests

This is an overview of browser requirements for AB Google Map Travel (AB-MAP)
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,856 ▲9514.82 ▲0.4711.03 ▲9.4543.57 ▲1.98
Dashboard /wp-admin2,204 ▲275.52 ▼0.0595.47 ▲5.6965.29 ▲24.08
Posts /wp-admin/edit.php2,124 ▲242.67 ▲0.6445.19 ▲1.7436.28 ▲0.73
Add New Post /wp-admin/post-new.php1,547 ▲1924.03 ▲0.81752.36 ▲68.8139.18 ▼19.64
Media Library /wp-admin/upload.php1,424 ▲245.08 ▲0.81112.47 ▲3.7276.79 ▲25.92

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 50% from 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 0% 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
Please fix the following items
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/ab-google-map-travel/ab-google-map-travel.php
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Notice
      Undefined variable: exit_msg in wp-content/plugins/ab-google-map-travel/ab-google-map-travel.php on line 14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
7 plugin tags: google travel, calculate distance, distance calculator, ab google map travel, google maps...

ab-google-map-travel/ab-google-map-travel.php 92% from 13 tests

"AB Google Map Travel (AB-MAP)" version 4.6's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
The following require your attention:
  • Description: Keep the plugin description shorter than 140 characters (currently 144 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected462 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP1719328
JavaScript18382
CSS10052

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.52
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%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/icon.png1.00KB0.89KB▼ 11.23%