94% amr-shortcode-any-widget

Code Review | amr shortcode any widget

WordPress plugin amr shortcode any widget scored 94% from 54 tests.

About plugin

  • Plugin page: amr-shortcode-any...
  • Plugin version: 4.0
  • PHP version: 7.4.16
  • WordPress version: 5.9.2
  • First release: Oct 24, 2009
  • Latest release: Aug 2, 2021
  • Number of updates: 95
  • Update frequency: every 45.4 days
  • Top authors: anmari (100%)

Code review

54 tests

User reviews

103 reviews

Install metrics

80,000+ active / 825,434 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼305.67ms] Passed 4 tests

Analyzing server-side resources used by amr shortcode any widget
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.67 ▲0.1558.76 ▲7.09
Dashboard /wp-admin3.51 ▲0.1034.39 ▼23.09
Posts /wp-admin/edit.php3.73 ▲0.09100.57 ▲46.49
Add New Post /wp-admin/post-new.php6.97 ▼0.0090.87 ▼1,207.26
Media Library /wp-admin/upload.php3.38 ▲0.0925.73 ▲0.59
Widgets /wp-admin/widgets.php5.25112.29
Shortcode any widget /wp-admin/options-general.php?page=amr_saw3.3523.33
Menus /wp-admin/nav-menus.php3.4928.48

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 10 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by amr shortcode any widget
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,786 ▲4215.83 ▲0.256.02 ▼0.332.39 ▼0.13
Dashboard /wp-admin2,904 ▲466.15 ▼0.02118.80 ▼17.43176.18 ▲10.00
Posts /wp-admin/edit.php2,703 ▲123.25 ▲0.0064.45 ▼5.97148.77 ▼4.30
Add New Post /wp-admin/post-new.php1,707 ▲2121.71 ▲3.60437.99 ▼20.44178.00 ▲17.69
Media Library /wp-admin/upload.php1,710 ▲125.41 ▼0.09142.95 ▼15.66190.26 ▼1.90
Widgets /wp-admin/widgets.php2,47123.76535.83143.73
Shortcode any widget /wp-admin/options-general.php?page=amr_saw1,1802.3668.39143.43
Menus /wp-admin/nav-menus.php2,2793.2884.24213.71

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Uninstall script ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/amr-shortcode-any-widget/amr-shortcode-any-widget.php:13

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 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
7 plugin tags: page template, templates, widget_area, widget, shortcode...

amr-shortcode-any-widget/amr-shortcode-any-widget.php 92% from 13 tests

"amr shortcode any widget" version 4.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
  • Description: Please keep the plugin description shorter than 140 characters (currently 272 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Success! There were no dangerous files found in this plugin701 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP415464585
PO File23976116

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity1.56
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods9100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions19
▷ Named functions19100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin