84% show-dimensions-in-library

Code Review | Show Dimensions in Library

WordPress plugin Show Dimensions in Library scored84%from 54 tests.

About plugin

  • Plugin page: show-dimensions-i...
  • Plugin version: 1.5
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.9
  • WordPress version: 6.3.1
  • First release: Jun 16, 2014
  • Latest release: Jun 19, 2018
  • Number of updates: 25
  • Update frequency: every 59.0 days
  • Top authors: DoubelJ (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

200+ active /2,547 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

Server-side resources used by Show Dimensions in Library
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0138.43 ▼0.70
Dashboard /wp-admin3.35 ▲0.0150.84 ▲2.82
Posts /wp-admin/edit.php3.40 ▲0.0153.08 ▲4.55
Add New Post /wp-admin/post-new.php5.93 ▲0.0194.43 ▼18.13
Media Library /wp-admin/upload.php3.27 ▲0.0135.10 ▲0.94

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Show Dimensions in Library
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲5414.74 ▲0.361.95 ▲0.1543.75 ▲5.23
Dashboard /wp-admin2,209 ▲185.89 ▲0.00103.76 ▼1.7942.71 ▲1.59
Posts /wp-admin/edit.php2,092 ▼02.05 ▲0.0544.33 ▲5.6239.52 ▲3.49
Add New Post /wp-admin/post-new.php1,533 ▼123.19 ▲0.01668.68 ▲69.4660.73 ▲5.46
Media Library /wp-admin/upload.php1,407 ▲224.22 ▲0.03101.46 ▲2.0542.34 ▼1.55

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
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
Almost there! Just 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/show-dimensions-in-library/jajadi-show-dimensions.php:77

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 errors were detected

Optimizations

Plugin configuration 96% from 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: admin, images, dimensions, media

show-dimensions-in-library/jajadi-show-dimensions.php 92% from 13 tests

The primary PHP file in "Show Dimensions in Library" version 1.5 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("show-dimensions-in-library.php" instead of "jajadi-show-dimensions.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin35 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1242635

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.21
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%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.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
PNG images were not found in this plugin