74% image-meta-save

Code Review | Image Meta Save

WordPress plugin Image Meta Save scored74%from 54 tests.

About plugin

  • Plugin page: image-meta-save
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.6
  • WordPress version: 6.3.1
  • First release: Jan 8, 2021
  • Latest release: Jan 8, 2021
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: blakebailey25 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /354 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼5.51ms] Passed 4 tests

A check of server-side resources used by Image Meta Save
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0738.30 ▼2.92
Dashboard /wp-admin3.37 ▲0.0745.98 ▼7.60
Posts /wp-admin/edit.php3.42 ▲0.0747.71 ▼0.30
Add New Post /wp-admin/post-new.php5.95 ▲0.0787.22 ▼11.00
Media Library /wp-admin/upload.php3.29 ▲0.0733.64 ▼0.53

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 7 new files
Database: 3 new tables, 6 new options
New tables
wp_imgMD_links
wp_imgMD_locations
wp_imgMD_presets
New WordPress options
widget_recent-posts
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Image Meta Save
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲8113.23 ▼1.144.64 ▲2.9237.91 ▼4.74
Dashboard /wp-admin2,222 ▲345.89 ▲0.91106.77 ▼9.3439.09 ▼6.45
Posts /wp-admin/edit.php2,102 ▲132.03 ▲0.0039.74 ▲4.9240.31 ▲6.61
Add New Post /wp-admin/post-new.php1,547 ▲1423.08 ▼0.50632.82 ▼39.9649.13 ▼0.78
Media Library /wp-admin/upload.php1,404 ▲164.23 ▼0.0094.69 ▼14.7843.61 ▼2.73

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Zombie tables were found after uninstall: 3 tables
    • wp_imgMD_locations
    • wp_imgMD_presets
    • wp_imgMD_links
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts

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
Even though everything seems fine, this is not an exhaustive test

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 take a closer look at the following
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/image-meta-save/ajax_functions.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/image-meta-save/image_meta_save.php:25

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
6 plugin tags: photos, metadata, preset, images, exif...

image-meta-save/image_meta_save.php 85% from 13 tests

"Image Meta Save" version 1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("image-meta-save.php" instead of "image_meta_save.php")
  • Description: Please keep the plugin description shorter than 140 characters (currently 166 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin868 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP38586474
JavaScript147118333
CSS113061

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.21
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%
Functions17
▷ Named functions17100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin