84% simple-static-google-maps

Code Review | Simple Static Google Maps

WordPress plugin Simple Static Google Maps scored84%from 54 tests.

About plugin

  • Plugin page: simple-static-goo...
  • Plugin version: 2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.4.2
  • WordPress version: 6.3.1
  • First release: Mar 5, 2010
  • Latest release: Mar 5, 2016
  • Number of updates: 11
  • Update frequency: every 199.5 days
  • Top authors: grimmdude (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /5,068 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.68MB] [CPU: ▼16.64ms] Passed 4 tests

Server-side resources used by Simple Static Google Maps
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0239.14 ▼1.72
Dashboard /wp-admin3.32 ▲0.0245.25 ▼0.27
Posts /wp-admin/edit.php3.37 ▲0.0247.56 ▼2.24
Add New Post /wp-admin/post-new.php3.11 ▼2.7833.99 ▼62.31
Media Library /wp-admin/upload.php3.24 ▲0.0235.37 ▲0.44

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

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

Browser metrics Passed 4 tests

Simple Static Google Maps: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.70 ▼0.705.31 ▲3.5942.69 ▲2.29
Dashboard /wp-admin2,203 ▲145.85 ▲0.91107.24 ▼14.8936.17 ▼7.13
Posts /wp-admin/edit.php2,092 ▲62.02 ▼0.0039.05 ▼0.8234.97 ▼0.41
Add New Post /wp-admin/post-new.php6,304 ▲4,78526.27 ▲3.12850.43 ▲192.8254.87 ▼13.49
Media Library /wp-admin/upload.php1,388 ▲64.19 ▲0.0196.38 ▼7.3341.98 ▼5.46

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-static-google-maps/simple-static-googlemaps.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Please fix the following attributes:
  • Screenshots: Screenshot #1 (Post meta box.) image not found
Please take inspiration from this readme.txt

simple-static-google-maps/simple-static-googlemaps.php 92% from 13 tests

The main file in "Simple Static Google Maps" v. 2.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("simple-static-google-maps.php" instead of "simple-static-googlemaps.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected114 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP12219114

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.68
Average class complexity15.00
▷ Minimum class complexity15.00
▷ Maximum class complexity15.00
Average method complexity3.80
▷ Minimum method complexity1.00
▷ Maximum method complexity7.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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.09MB with 0.05MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png62.99KB22.61KB▼ 64.11%
screenshot-2.png24.63KB9.54KB▼ 61.25%