89% blocks-google-map

Code Review | Blocks Google Map

WordPress plugin Blocks Google Map scored89%from 54 tests.

About plugin

  • Plugin page: blocks-google-map
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.9
  • WordPress version: 6.3.1
  • First release: Aug 3, 2018
  • Latest release: Aug 3, 2018
  • Number of updates: 6
  • Update frequency: every 2.0 days
  • Top authors: gk.loveweb (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /758 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
This plugin's installer ran successfully

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

Server-side resources used by Blocks Google Map
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0336.69 ▼3.40
Dashboard /wp-admin3.32 ▲0.0251.34 ▼1.42
Posts /wp-admin/edit.php3.37 ▲0.0248.22 ▼5.39
Add New Post /wp-admin/post-new.php5.90 ▲0.0281.48 ▼22.31
Media Library /wp-admin/upload.php3.25 ▲0.0234.73 ▼1.15

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Blocks Google Map
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,953 ▲18222.95 ▲8.66191.44 ▲189.4242.16 ▼1.12
Dashboard /wp-admin2,222 ▲345.79 ▼0.2194.19 ▼12.1940.83 ▼2.75
Posts /wp-admin/edit.php2,105 ▲132.03 ▼0.0235.53 ▼4.6729.35 ▼5.08
Add New Post /wp-admin/post-new.php6,209 ▲4,68819.37 ▼3.71930.15 ▲310.2440.69 ▼7.78
Media Library /wp-admin/upload.php1,404 ▲164.15 ▼0.0398.60 ▲3.0742.60 ▲0.70

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 were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 93% 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 to be fixed:
  • Tags: Please delete some tags, you are using 45 tag instead of maximum 10
The official readme.txt might help

blocks-google-map/gutenberg-map.php 92% from 13 tests

The entry point to "Blocks Google Map" version 1.0.0 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("blocks-google-map.php" instead of "gutenberg-map.php")

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
Success! There were no dangerous files found in this plugin155 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
CSS112089
PHP1186263
JavaScript10123

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.05
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
1 PNG file occupies 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/google-maps.png54.01KB22.38KB▼ 58.57%