88% thumbnailsforbackend

Code Review | Thumbnails for Backend

WordPress plugin Thumbnails for Backend scored 88% from 54 tests.

About plugin

  • Plugin page: thumbnailsforbackend
  • Plugin version: 0.0.5
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.5.1
  • WordPress version: 5.8.1
  • First release: Nov 21, 2011
  • Latest release: Apr 6, 2013
  • Number of updates: 15
  • Update frequency: every 33.5 days
  • Top authors: g100g (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

1,000+ active / 7,873 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼148.09ms] Passed 4 tests

A check of server-side resources used by Thumbnails for Backend
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.86 ▲0.1437.05 ▲11.41
Dashboard /wp-admin3.10 ▲0.0446.53 ▲0.38
Posts /wp-admin/edit.php3.15 ▲0.0438.30 ▼15.65
Add New Post /wp-admin/post-new.php5.46 ▲0.0297.19 ▼577.44
Media Library /wp-admin/upload.php3.04 ▲0.0436.19 ▲0.37

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Thumbnails for Backend: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,708 ▲10216.34 ▲0.7910.56 ▼0.7353.47 ▼2.22
Dashboard /wp-admin2,975 ▲415.95 ▼0.21145.82 ▼9.42120.01 ▲6.29
Posts /wp-admin/edit.php2,744 ▲52.72 ▲0.0171.45 ▼10.1899.07 ▼4.59
Add New Post /wp-admin/post-new.php1,686 ▼2,04018.77 ▲3.55389.53 ▼90.12119.74 ▼7.59
Media Library /wp-admin/upload.php1,812 ▲25.02 ▼0.01158.90 ▼4.85128.42 ▼4.84
Thumbnails for Backend /wp-admin/thumbnailsforbackend.php260.900.0611.83

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstaller ran successfully

Smoke tests 50% 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)
Good news, no errors were detected

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
Almost there! Just fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/thumbnailsforbackend/thumbnailsforbackend.php:328

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please fix the following user-side errors
    • > GET request to /wp-admin/thumbnailsforbackend.php
    • > Network (severe)
    wp-admin/thumbnailsforbackend.php - Failed to load resource: the server responded with a status of 404 (Not Found)


Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Preview), #2 (Setting Page)
You can look at the official readme.txt

thumbnailsforbackend/thumbnailsforbackend.php Passed 13 tests

Analyzing the main PHP file in "Thumbnails for Backend" version 0.0.5
80 characters long description:
Simple plugin to add thumbnails to your Posts list within the WordPress backend.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin182 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity25.00
▷ Minimum class complexity25.00
▷ Maximum class complexity25.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods1083.33%
▷ Protected methods00.00%
▷ Private methods216.67%
▷ Named functions00.00%
▷ Anonymous functions00.00%
▷ 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
2 PNG files occupy 0.06MB with 0.04MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png48.91KB21.73KB▼ 55.57%
screenshot-2.png15.75KB6.23KB▼ 60.45%