90% geo-masala

Code Review | Geo Masala

WordPress plugin Geo Masala scored90%from 54 tests.

About plugin

  • Plugin page: geo-masala
  • Plugin version: 0.1.4
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.6-4.9.8
  • WordPress version: 6.3.1
  • First release: Jul 14, 2018
  • Latest release: Dec 8, 2019
  • Number of updates: 12
  • Update frequency: every 42.7 days
  • Top authors: jhotadhari (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,209 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.17MB] [CPU: ▼6.23ms] Passed 4 tests

An overview of server-side resources used by Geo Masala
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.64 ▲0.1836.46 ▼6.87
Dashboard /wp-admin3.46 ▲0.1145.57 ▼13.85
Posts /wp-admin/edit.php3.57 ▲0.2246.20 ▼1.13
Add New Post /wp-admin/post-new.php6.14 ▲0.2683.92 ▼3.07
Media Library /wp-admin/upload.php3.38 ▲0.1535.97 ▲1.43

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 52 new files
Database: no new tables, 8 new options
New WordPress options
can_compress_scripts
widget_recent-comments
geom_version
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
geom_db_version
db_upgraded

Browser metrics Passed 4 tests

Geo Masala: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,928 ▲15714.76 ▲0.3720.02 ▲17.8041.75 ▼3.91
Dashboard /wp-admin2,206 ▲184.86 ▲0.03111.28 ▼4.3843.81 ▼2.11
Posts /wp-admin/edit.php2,089 ▼01.99 ▼0.0244.54 ▲8.2234.72 ▲0.98
Add New Post /wp-admin/post-new.php6,206 ▲4,67322.35 ▼0.79894.21 ▲222.9952.18 ▼14.88
Media Library /wp-admin/upload.php1,388 ▲34.14 ▼0.04102.06 ▼8.4741.32 ▼3.90

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin does not fully uninstall, leaving 8 options in the database
    • can_compress_scripts
    • geom_version
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • geom_db_version
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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

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)
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
6 plugin tags: geo, gutenberg, gis, leaflet, block...

geo-masala/geo-masala.php 92% from 13 tests

The main PHP script in "Geo Masala" version 0.1.4 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist

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
Everything looks great! No dangerous files found in this plugin1,400 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
PHP142572881,055
SVG100156
Markdown1490147
JavaScript60038
CSS3003
JSON1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.52
Average class complexity23.43
▷ Minimum class complexity1.00
▷ Maximum class complexity53.00
Average method complexity3.45
▷ Minimum method complexity1.00
▷ Maximum method complexity40.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods65
▷ Static methods1320.00%
▷ Public methods5483.08%
▷ Protected methods1015.38%
▷ Private methods11.54%
Functions8
▷ Named functions787.50%
▷ Anonymous functions112.50%
Constants5
▷ Global constants00.00%
▷ Class constants5100.00%
▷ Public constants5100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
23 compressed PNG files occupy 0.03MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/leaflet-fullscreen/icon-fullscreen-2x.png0.21KB0.24KB0.00%
images/leaflet-draw/layers.png0.68KB1.05KB0.00%
images/icon-center.png0.53KB0.70KB0.00%
images/icon-cancel-2x.png1.41KB1.40KB▼ 0.76%
images/leaflet-draw-toolbar/spritesheet-2x.png3.50KB2.20KB▼ 37.00%