84% media-manager-blocks

Code Review | Block Editor Media Manager

WordPress plugin Block Editor Media Manager scored 84% from 54 tests.

About plugin

  • Plugin page: media-manager-blocks
  • Plugin version: 0.0.1
  • PHP compatiblity: 7.0.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6.0-5.8.0
  • WordPress version: 6.3.1
  • First release: Jul 27, 2021
  • Latest release: Jul 29, 2021
  • Number of updates: 3
  • Update frequency: every 0.7 days
  • Top authors: retrofox (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 352 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
Install script ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼0.41ms] Passed 4 tests

This is a short check of server-side resources used by Block Editor Media Manager
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0737.42 ▼5.78
Dashboard /wp-admin3.34 ▲0.0345.26 ▼2.03
Posts /wp-admin/edit.php3.39 ▲0.0346.46 ▼0.61
Add New Post /wp-admin/post-new.php5.94 ▲0.0698.04 ▲7.14
Media Library /wp-admin/upload.php3.26 ▲0.0335.86 ▲6.76

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 60 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Block Editor Media Manager
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,966 ▲20920.64 ▲6.06137.79 ▲135.4250.06 ▲0.29
Dashboard /wp-admin2,209 ▲215.76 ▲0.8893.46 ▼22.7638.38 ▼5.63
Posts /wp-admin/edit.php2,089 ▼01.98 ▼0.0639.50 ▲1.4735.77 ▲2.36
Add New Post /wp-admin/post-new.php6,415 ▲4,90120.58 ▲3.10931.61 ▲252.0638.96 ▼10.89
Media Library /wp-admin/upload.php1,388 ▼34.21 ▲0.0491.31 ▼10.7343.63 ▲0.49

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
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% 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
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function FancyBlocks\\MediaManager\\add_action() in wp-content/plugins/media-manager-blocks/media-manager.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: block, media-manager, audio, media, video...

media-manager-blocks/media-manager.php 85% from 13 tests

The primary PHP file in "Block Editor Media Manager" version 0.0.1 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("media-manager-blocks.php" instead of "media-manager.php")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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
Good job! No executable or dangerous file extensions detected1,109 lines of code in 54 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript34114226665
Sass9236199
JSON600156
PHP3202780
CSS2409

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.28
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%
Functions4
▷ Named functions375.00%
▷ Anonymous functions125.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
There were not PNG files found in your plugin