84% auto-thumbnailer

Code Review | Auto Thumbnailer

WordPress plugin Auto Thumbnailer scored84%from 54 tests.

About plugin

  • Plugin page: auto-thumbnailer
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.6
  • WordPress version: 6.3.1
  • First release: Aug 2, 2013
  • Latest release: Aug 2, 2013
  • Number of updates: 4
  • Update frequency: N/A
  • Top authors: peterchester (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

400+ active /14,018 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.04MB] [CPU: ▼3.75ms] Passed 4 tests

An overview of server-side resources used by Auto Thumbnailer
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0539.34 ▼2.11
Dashboard /wp-admin3.35 ▲0.0448.78 ▼4.95
Posts /wp-admin/edit.php3.40 ▲0.0446.66 ▼8.88
Add New Post /wp-admin/post-new.php5.93 ▲0.0497.12 ▲0.93
Media Library /wp-admin/upload.php3.27 ▲0.0436.56 ▲4.11

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

Auto Thumbnailer: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.24 ▼0.111.79 ▼1.0540.46 ▼6.16
Dashboard /wp-admin2,195 ▲185.61 ▲0.0083.75 ▼13.9938.63 ▼2.70
Posts /wp-admin/edit.php2,109 ▲61.99 ▼0.0241.81 ▼2.8437.72 ▲0.68
Add New Post /wp-admin/post-new.php1,528 ▼023.20 ▲0.12589.38 ▼80.3261.52 ▲9.01
Media Library /wp-admin/upload.php1,400 ▼34.21 ▼0.0199.53 ▲3.1044.92 ▲0.15

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
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options

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 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/auto-thumbnailer/views/warning.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_theme_support() in wp-content/plugins/auto-thumbnailer/auto-thumbnailer.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
4 plugin tags: media, oembed, thumbnail, image

auto-thumbnailer/auto-thumbnailer.php Passed 13 tests

"Auto Thumbnailer" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
118 characters long description:
Automatically create thumbnails for posts when images are uploaded and the post is saved. Includes support for Oembed.

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 plugin195 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP23821195

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity46.00
▷ Minimum class complexity46.00
▷ Maximum class complexity46.00
Average method complexity6.00
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods777.78%
▷ Protected methods00.00%
▷ Private methods222.22%
Functions0
▷ Named functions00.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
No PNG images were found in this plugin