83% asr-google-map

Code Review | ASR Google Map

WordPress plugin ASR Google Map scored 83% from 54 tests.

About plugin

  • Plugin page: asr-google-map
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress version: 5.9.2
  • First release: Oct 17, 2017
  • Latest release: Oct 17, 2017
  • Number of updates: 7
  • Update frequency: every 0.3 days
  • Top authors: mdshuvo (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 491 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼1.45MB] [CPU: ▼334.79ms] Passed 4 tests

This is a short check of server-side resources used by ASR Google Map
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.00 ▼0.5216.24 ▼34.19
Dashboard /wp-admin2.92 ▼0.4915.56 ▼17.03
Posts /wp-admin/edit.php2.92 ▼0.7215.22 ▼22.81
Add New Post /wp-admin/post-new.php2.92 ▼4.0513.93 ▼1,265.12
Media Library /wp-admin/upload.php2.92 ▼0.3813.56 ▼10.63
Add New Map /wp-admin/post-new.php?post_type=gmap-pro2.9214.87
All Maps /wp-admin/edit.php?post_type=gmap-pro2.9214.42
Map Setting /wp-admin/edit.php?post_type=gmap-pro&page=setting2.9214.59

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 17 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

ASR Google Map: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,840 ▲8617.30 ▲1.1814.88 ▲8.792.19 ▼1.28
Dashboard /wp-admin2,939 ▲856.23 ▲0.03117.72 ▼17.38156.61 ▼6.24
Posts /wp-admin/edit.php2,735 ▲413.24 ▲0.0063.06 ▼0.66141.13 ▲5.31
Add New Post /wp-admin/post-new.php1,789 ▲3723.02 ▲2.04420.23 ▼47.07154.02 ▼8.78
Media Library /wp-admin/upload.php1,743 ▲455.46 ▼0.06147.35 ▼6.63183.50 ▼8.98
Add New Map /wp-admin/post-new.php?post_type=gmap-pro2,0854.1293.65143.51
All Maps /wp-admin/edit.php?post_type=gmap-pro1,4242.9361.82113.09
Map Setting /wp-admin/edit.php?post_type=gmap-pro&page=setting1,0642.3853.66108.13

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • This plugin cannot be uninstalled
    • > Warning in wp-includes/class-wp-post-type.php+582
    Invalid argument supplied for foreach()

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Please fix the following server-side errors
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=gmap-pro&page=setting
    • > Warning in wp-includes/class-wp-post-type.php+582
    Invalid argument supplied for foreach()

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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% 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:
  • Tags: Please reduce the number of tags, currently 13 tag instead of maximum 10
You can take inspiration from this readme.txt

asr-google-map/asr-google-map.php 77% from 13 tests

Analyzing the main PHP file in "ASR Google Map" version 1.0
You should first fix the following items:
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist
  • Description: Keep the plugin description shorter than 140 characters (currently 145 characters long)
  • Text Domain: Please use dashes and lowercase characters for text domains

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
No dangerous file extensions were detected341 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP64873222
CSS118285
JavaScript16034

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.29
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%
Functions14
▷ Named functions14100.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
3 PNG files occupy 0.48MB with 0.28MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-3.png396.11KB107.52KB▼ 72.86%
screenshot-1.png44.14KB21.22KB▼ 51.93%
screenshot-2.png50.13KB24.97KB▼ 50.18%