84% block-minimap

Code Review | Block Minimap

WordPress plugin Block Minimap scored84%from 54 tests.

About plugin

  • Plugin page: block-minimap
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.3
  • WordPress version: 6.3.1
  • First release: Oct 21, 2019
  • Latest release: Oct 21, 2019
  • Number of updates: 3
  • Update frequency: every 7.0 days
  • Top authors: adamsilverstein (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,274 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.57ms] Passed 4 tests

Server-side resources used by Block Minimap
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0039.18 ▼3.96
Dashboard /wp-admin3.31 ▲0.0052.93 ▲0.33
Posts /wp-admin/edit.php3.36 ▲0.0048.43 ▼9.06
Add New Post /wp-admin/post-new.php5.89 ▲0.0091.36 ▼11.42
Media Library /wp-admin/upload.php3.23 ▲0.0036.91 ▼1.85

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Block Minimap
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲5413.19 ▼1.191.67 ▼0.3741.55 ▼3.55
Dashboard /wp-admin2,218 ▲125.06 ▲0.14101.37 ▼12.1337.19 ▼10.67
Posts /wp-admin/edit.php2,100 ▼31.98 ▼0.0136.53 ▼7.3334.58 ▼3.52
Add New Post /wp-admin/post-new.php1,547 ▲1623.58 ▲0.50641.47 ▼40.3559.79 ▲0.52
Media Library /wp-admin/upload.php1,397 ▲34.24 ▼0.03104.31 ▼8.4945.09 ▲0.65

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 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
Please take a closer look at the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function BlockMinimap\\add_action() in wp-content/plugins/block-minimap/block-minimap.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that need to be fixed: You can take inspiration from this readme.txt

block-minimap/block-minimap.php 92% from 13 tests

The main PHP file in "Block Minimap" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug

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 detected9,038 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
JSON2008,449
JavaScript68089403
Markdown5580113
CSS19061
PHP121812

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.00
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
Namespaces1
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%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin