90% as-metabox

Code Review | AS Metabox

WordPress plugin AS Metabox scored90%from 54 tests.

About plugin

  • Plugin page: as-metabox
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Aug 31, 2017
  • Latest release: Aug 31, 2017
  • Number of updates: 17
  • Update frequency: every 0.4 days
  • Top authors: anuislam (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /694 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.36MB] [CPU: ▼0.71ms] Passed 4 tests

An overview of server-side resources used by AS Metabox
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.83 ▲0.3742.15 ▲0.72
Dashboard /wp-admin3.68 ▲0.3847.72 ▼8.53
Posts /wp-admin/edit.php3.73 ▲0.3849.07 ▼0.35
Add New Post /wp-admin/post-new.php6.25 ▲0.36102.29 ▲12.50
Media Library /wp-admin/upload.php3.54 ▲0.3140.66 ▲5.31

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 46 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for AS Metabox
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.66 ▼0.771.72 ▼0.3542.85 ▼3.78
Dashboard /wp-admin2,206 ▲185.87 ▲1.02106.37 ▲3.9542.41 ▲3.32
Posts /wp-admin/edit.php2,089 ▼02.04 ▲0.0444.34 ▲4.1334.51 ▼2.32
Add New Post /wp-admin/post-new.php7,259 ▲5,72622.06 ▼1.23959.92 ▲288.81100.00 ▲47.32
Media Library /wp-admin/upload.php1,391 ▲34.20 ▲0.0093.74 ▼1.2242.70 ▲0.22

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
  • Tags: Please delete some tags, you are using 11 tag instead of maximum 10
The official readme.txt might help

as-metabox/as-metabox.php Passed 13 tests

"AS Metabox" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
51 characters long description:
As Metabox Easy To Use WordPress Metabox Framework.

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
There were no executable files found in this plugin7,237 lines of code in 32 files:
LanguageFilesBlank linesComment linesLines of code
SVG1002,671
PHP26364782,514
CSS4384201,744
JavaScript1758308

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity11.00
▷ Minimum class complexity1.00
▷ Maximum class complexity56.00
Average method complexity3.38
▷ Minimum method complexity1.00
▷ Maximum method complexity33.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes19
▷ Abstract classes00.00%
▷ Concrete classes19100.00%
▷ Final classes00.00%
Methods80
▷ Static methods00.00%
▷ Public methods80100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions7
▷ Named functions685.71%
▷ Anonymous functions114.29%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
6 PNG files occupy 0.04MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/css/images/ui-icons_cc0000_256x240.png4.52KB4.18KB▼ 7.56%
assets/css/images/ui-icons_555555_256x240.png6.91KB4.18KB▼ 39.47%
assets/css/images/ui-icons_ffffff_256x240.png6.17KB4.18KB▼ 32.17%
assets/css/images/ui-icons_777777_256x240.png6.85KB4.18KB▼ 38.94%
assets/css/images/ui-icons_444444_256x240.png6.84KB4.18KB▼ 38.90%