84% auto-gallery-image-sync

Code Review | Auto Gallery And Image Sync

WordPress plugin Auto Gallery And Image Sync scored84%from 54 tests.

About plugin

  • Plugin page: auto-gallery-imag...
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.3
  • WordPress version: 6.3.1
  • First release: Oct 14, 2022
  • Latest release: Aug 12, 2023
  • Number of updates: 9
  • Update frequency: every 33.6 days
  • Top authors: atakanau (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /663 total downloads


Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.12MB] [CPU: ▼3.10ms] Passed 4 tests

Server-side resources used by Auto Gallery And Image Sync
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.1235.83 ▼3.96
Dashboard /wp-admin3.43 ▲0.1244.71 ▼2.59
Posts /wp-admin/edit.php3.54 ▲0.1948.69 ▲2.42
Add New Post /wp-admin/post-new.php6.01 ▲0.1289.25 ▼8.27
Media Library /wp-admin/upload.php3.35 ▲0.1236.48 ▲3.68
Sync images /wp-admin/tools.php?page=auto-gallery-image-sync3.3637.82

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Auto Gallery And Image Sync
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲8313.21 ▼1.401.77 ▼0.0940.70 ▲3.20
Dashboard /wp-admin2,210 ▲254.85 ▼0.96110.60 ▼2.4542.83 ▲0.95
Posts /wp-admin/edit.php2,093 ▲12.05 ▼0.1339.49 ▼4.2839.12 ▼1.29
Add New Post /wp-admin/post-new.php1,517 ▼1117.70 ▼5.49604.61 ▼9.7153.06 ▲6.01
Media Library /wp-admin/upload.php1,395 ▲104.21 ▼0.0494.22 ▼7.6241.70 ▼2.21
Sync images /wp-admin/tools.php?page=auto-gallery-image-sync1,2592.0827.0243.03

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
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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 take a closer look at the following
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to a member function prepare_items() on null in wp-content/plugins/auto-gallery-image-sync/admin/partials/auto-gallery-image-sync-admin-display.php:16
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/auto-gallery-image-sync/admin/class-auto-gallery-image-sync-admin.php on line 26
    • > PHP Notice
      Undefined variable: agisync_atakanau in wp-content/plugins/auto-gallery-image-sync/admin/partials/auto-gallery-image-sync-admin-display.php on line 16
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/auto-gallery-image-sync/admin/class-auto-gallery-image-sync-admin.php on line 26
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/auto-gallery-image-sync/admin/class-auto-gallery-image-sync-admin.php on line 26

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)
Everything seems fine, but this is not an exhaustive test


Plugin configuration Passed 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
5 plugin tags: gallery, auto, image, sync, featured image

auto-gallery-image-sync/auto-gallery-image-sync.php Passed 13 tests

The principal PHP file in "Auto Gallery And Image Sync" v. 1.0.0 is loaded by WordPress automatically on each request
97 characters long description:
Automatically sync posts (or WooCommerce Product) and media images as featured image and gallery.

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
No dangerous file extensions were detected768 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PO File131692

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity9.00
▷ Minimum class complexity1.00
▷ Maximum class complexity52.00
Average method complexity2.24
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
▷ Static methods24.44%
▷ Public methods3168.89%
▷ Protected methods511.11%
▷ Private methods920.00%
▷ Named functions3100.00%
▷ Anonymous functions00.00%
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin