84% media-thumbnail-enlarger

Code Review | Media Library Thumbnail Enhancer

WordPress plugin Media Library Thumbnail Enhancer scored84%from 54 tests.

About plugin

  • Plugin page: media-thumbnail-e...
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.2-3.8.1
  • WordPress version: 6.3.1
  • First release: Mar 24, 2014
  • Latest release: Mar 27, 2014
  • Number of updates: 31
  • Update frequency: every 0.1 days
  • Top authors: nickciske (100%)

Code review

54 tests

User reviews

1 review

Install metrics

70+ active /2,982 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▲0.25ms] Passed 4 tests

This is a short check of server-side resources used by Media Library Thumbnail Enhancer
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0241.67 ▼1.47
Dashboard /wp-admin3.34 ▲0.0349.79 ▼0.80
Posts /wp-admin/edit.php3.39 ▲0.0349.88 ▼3.01
Add New Post /wp-admin/post-new.php5.92 ▲0.0392.65 ▲6.26
Media Library /wp-admin/upload.php3.26 ▲0.0342.09 ▲6.64

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Media Library Thumbnail Enhancer
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,791 ▲3014.39 ▼0.341.86 ▲0.1043.40 ▼0.67
Dashboard /wp-admin2,197 ▲165.63 ▼0.0890.30 ▼15.2337.34 ▼7.98
Posts /wp-admin/edit.php2,105 ▲22.02 ▼0.0039.41 ▲1.8735.35 ▼3.71
Add New Post /wp-admin/post-new.php1,528 ▲223.27 ▲0.05678.20 ▼71.5852.55 ▼13.89
Media Library /wp-admin/upload.php1,401 ▲14.17 ▼0.0099.45 ▼11.4443.04 ▼5.91

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

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
Please take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/media-thumbnail-enlarger/media-thumbnail-enlarger.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need to be fixed: The official readme.txt might help

media-thumbnail-enlarger/media-thumbnail-enlarger.php Passed 13 tests

The main file in "Media Library Thumbnail Enhancer" v. 1.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
114 characters long description:
Enhances media library thumbnails by making them larger and replacing the bundled icons with scalable SVG versions

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Good job! No executable or dangerous file extensions detected190 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP1471987
SVG80886
CSS14117

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.19
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%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
9 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
icons/default/spreadsheet.png1.81KB1.18KB▼ 34.95%
icons/default/video.png1.62KB0.85KB▼ 47.32%
icons/default/text.png1.78KB1.14KB▼ 36.00%
icons/default/audio.png2.58KB2.10KB▼ 18.85%
icons/default/code.png2.28KB1.54KB▼ 32.59%