62% interactive-svg-map

Code Review | Interactive SVG Map

WordPress plugin Interactive SVG Map scored62%from 54 tests.

About plugin

  • Plugin page: interactive-svg-map
  • Plugin version: 3.0.0
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jun 8, 2016
  • Latest release: Jan 5, 2021
  • Number of updates: 13
  • Update frequency: every 128.6 days
  • Top authors: pawaryogesh1989 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /7,194 total downloads

Benchmarks

Plugin footprint 65% 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.92MB] [CPU: ▼37.12ms] Passed 4 tests

Server-side resources used by Interactive SVG Map
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0654.26 ▲13.23
Dashboard /wp-admin3.03 ▼0.2824.22 ▼28.34
Posts /wp-admin/edit.php3.03 ▼0.3322.86 ▼30.23
Add New Post /wp-admin/post-new.php3.03 ▼2.8623.22 ▼80.14
Media Library /wp-admin/upload.php3.03 ▼0.2126.05 ▼9.77
Interactive Map Settings /wp-admin/plugins.php?page=interactive-map-settings3.1322.17

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Interactive SVG Map
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲6414.67 ▲0.303.71 ▲1.9841.59 ▼2.18
Dashboard /wp-admin2,218 ▲385.81 ▲0.2199.04 ▲7.3141.92 ▲3.41
Posts /wp-admin/edit.php2,128 ▲282.31 ▲0.2837.84 ▲1.8034.05 ▼0.43
Add New Post /wp-admin/post-new.php1,543 ▲1723.49 ▲0.30696.79 ▲12.5437.05 ▼24.94
Media Library /wp-admin/upload.php1,423 ▲264.45 ▲0.21100.89 ▼16.1843.91 ▼6.94
Interactive Map Settings /wp-admin/plugins.php?page=interactive-map-settings1,7323.0360.4028.60

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • Uninstall procedure had uncaught errors
    • > User notice in wp-includes/functions.php+5905
    Function add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/plugins.php?page=interactive-map-settings
    • > User notice in wp-includes/functions.php+5905
    Function add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/interactive-svg-map/interactive-svg-map.php
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/interactive-svg-map/views/interactive-map-settings.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% 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:
  • Requires at least: Invalid version format
  • Tags: Please delete some tags, you are using 28 tag instead of maximum 10
You can take inspiration from this readme.txt

interactive-svg-map/interactive-svg-map.php 92% from 13 tests

The principal PHP file in "Interactive SVG Map" v. 3.0.0 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Text Domain: The text domain should only use lowercase characters and dashes

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected1,478 lines of code in 30 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript24239451,119
PHP32238215
CSS3134144

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.14
Average class complexity14.00
▷ Minimum class complexity14.00
▷ Maximum class complexity14.00
Average method complexity2.86
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.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

PNG files should be compressed to save space and minimize bandwidth usage
26 PNG files occupy 0.28MB with 0.21MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/css/images/flag.png1.68KB1.56KB▼ 7.37%
assets/images/marker/yellow.png16.95KB1.67KB▼ 90.12%
assets/css/images/marker/black.png16.68KB1.54KB▼ 90.78%
assets/css/images/marker/purple.png16.96KB1.67KB▼ 90.13%
assets/css/images/marker/blue.png16.95KB1.67KB▼ 90.12%