84% image-rotation-repair

Code Review | Image Rotation Repair

WordPress plugin Image Rotation Repair scored 84% from 54 tests.

About plugin

  • Plugin page: image-rotation-re...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.2
  • WordPress version: 6.3.1
  • First release: Dec 14, 2010
  • Latest release: Aug 31, 2012
  • Number of updates: 12
  • Update frequency: every 52.2 days
  • Top authors: peterchester (100%)

Code review

54 tests

User reviews

9 reviews

Install metrics

8,000+ active / 23,044 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

This is a short check of server-side resources used by Image Rotation Repair
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0135.47 ▼1.90
Dashboard /wp-admin3.31 ▲0.0147.23 ▼1.92
Posts /wp-admin/edit.php3.36 ▲0.0149.86 ▲3.12
Add New Post /wp-admin/post-new.php5.89 ▲0.0193.86 ▼2.05
Media Library /wp-admin/upload.php3.23 ▲0.0039.72 ▲7.40

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Image Rotation Repair
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.28 ▼1.311.56 ▼0.1239.14 ▼3.31
Dashboard /wp-admin2,206 ▲155.89 ▲0.95106.00 ▼2.5242.06 ▲0.36
Posts /wp-admin/edit.php2,089 ▼01.99 ▼0.0140.30 ▲4.2934.13 ▲1.97
Add New Post /wp-admin/post-new.php1,533 ▼023.38 ▲0.05656.88 ▼11.9157.78 ▲5.68
Media Library /wp-admin/upload.php1,385 ▼34.19 ▲0.0292.79 ▼17.6542.57 ▼2.99

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

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/image-rotation-repair/image-rotation-repair.php:20

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
8 plugin tags: rotation, image, iphone, email content, orientation...

image-rotation-repair/image-rotation-repair.php 92% from 13 tests

"Image Rotation Repair" version 1.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Description: The description should be shorter than 140 characters (currently 348 characters long)

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
Everything looks great! No dangerous files found in this plugin87 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP171187

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.54
Average class complexity22.00
▷ Minimum class complexity22.00
▷ Maximum class complexity22.00
Average method complexity6.25
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
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

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected