84% adm-media-list

Code Review | ADM Media List

WordPress plugin ADM Media List scored84%from 54 tests.

About plugin

  • Plugin page: adm-media-list
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.2.4
  • WordPress version: 6.3.1
  • First release: Oct 29, 2019
  • Latest release: Oct 29, 2019
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: adriangeorgel (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /4,465 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼7.68ms] Passed 4 tests

An overview of server-side resources used by ADM Media List
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0140.42 ▼10.33
Dashboard /wp-admin3.32 ▲0.0148.88 ▼7.22
Posts /wp-admin/edit.php3.37 ▲0.0147.41 ▼1.29
Add New Post /wp-admin/post-new.php5.92 ▲0.0387.40 ▼10.77
Media Library /wp-admin/upload.php3.24 ▲0.0135.53 ▼2.40

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for ADM Media List
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,826 ▲6514.75 ▲0.381.76 ▼0.1543.39 ▼6.09
Dashboard /wp-admin2,232 ▲525.64 ▲0.0184.13 ▼4.0839.28 ▼8.80
Posts /wp-admin/edit.php2,104 ▲41.98 ▼0.0437.74 ▼3.8033.67 ▼6.89
Add New Post /wp-admin/post-new.php1,530 ▲423.32 ▲2.42694.00 ▲52.2959.15 ▲3.52
Media Library /wp-admin/upload.php1,407 ▲44.20 ▼0.0797.49 ▼4.9043.32 ▼0.69

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

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

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
The following issues need your attention
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/adm-media-list/adm-media-list.php:25

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 Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
4 plugin tags: media library urls, media list, media library, url list

adm-media-list/adm-media-list.php Passed 13 tests

"ADM Media List" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
95 characters long description:
Adds a widget to the dashboard that displays a list of urls for each item in the media library.

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
Success! There were no dangerous files found in this plugin78 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
CSS12136
PHP1181236
JavaScript1346

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.12
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
Namespaces0
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%
Functions3
▷ Named functions3100.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
2 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/icon-128x128.png8.50KB3.10KB▼ 63.52%
assets/icon-256x256.png8.50KB3.10KB▼ 63.52%