89% magni-image-flip-for-woocommerce

Code Review | Magni Image Flip For WooCommerce

WordPress plugin Magni Image Flip For WooCommerce scored89%from 54 tests.

About plugin

  • Plugin page: magni-image-flip-...
  • Plugin version: 1.2
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Nov 20, 2018
  • Latest release: Sep 4, 2023
  • Number of updates: 10
  • Update frequency: every 175.1 days
  • Top authors: Magnigenie (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

1,000+ active /15,500 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
Install script ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼10.11ms] Passed 4 tests

An overview of server-side resources used by Magni Image Flip For WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0041.60 ▼3.52
Dashboard /wp-admin3.31 ▲0.0048.80 ▼4.35
Posts /wp-admin/edit.php3.36 ▲0.0051.72 ▼0.53
Add New Post /wp-admin/post-new.php5.89 ▲0.0086.28 ▼24.43
Media Library /wp-admin/upload.php3.23 ▲0.0035.13 ▼8.13

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 13 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Magni Image Flip For WooCommerce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,807 ▲4614.36 ▼0.261.63 ▼0.3045.48 ▲2.03
Dashboard /wp-admin2,198 ▲215.59 ▼0.0892.03 ▲4.1339.36 ▼5.85
Posts /wp-admin/edit.php2,100 ▼01.97 ▲0.0139.67 ▲0.9835.71 ▼3.46
Add New Post /wp-admin/post-new.php1,526 ▼023.65 ▲0.53660.41 ▼26.4662.01 ▼0.22
Media Library /wp-admin/upload.php1,400 ▲34.19 ▼0.02103.91 ▼12.4544.66 ▼4.03

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

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

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
7 plugin tags: woocommerce image flip, image flip plugin, woocommerce gallery, woocommerce, woocommerce addon...

magni-image-flip-for-woocommerce/magni-image.php 77% from 13 tests

The main PHP script in "Magni Image Flip For WooCommerce" version 1.2 is automatically included on every request by WordPress
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("magni-image-flip-for-woocommerce.php" instead of "magni-image.php")
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Description: The description should be shorter than 140 characters (currently 170 characters long)

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
No dangerous file extensions were detected6,431 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript61,3633565,734
CSS2673465
PHP35978232

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity9.00
▷ Minimum class complexity1.00
▷ Maximum class complexity17.00
Average method complexity2.45
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods11
▷ Static methods00.00%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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