83% aotomot-gallery

Code Review | Aotomot Gallery

WordPress plugin Aotomot Gallery scored 83% from 54 tests.

About plugin

  • Plugin page: aotomot-gallery
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0.0-5.3.2
  • WordPress version: 5.8.1
  • First release: Feb 9, 2020
  • Latest release: Feb 10, 2020
  • Number of updates: 3
  • Update frequency: every 1.0 days
  • Top authors: aotomot (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 213 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.23MB] [CPU: ▼157.00ms] Passed 4 tests

This is a short check of server-side resources used by Aotomot Gallery
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.00 ▲0.2837.08 ▲10.11
Dashboard /wp-admin3.33 ▲0.2853.58 ▼10.70
Posts /wp-admin/edit.php3.38 ▲0.2850.67 ▼12.57
Add New Post /wp-admin/post-new.php5.60 ▲0.17100.60 ▼602.03
Media Library /wp-admin/upload.php3.19 ▲0.1934.94 ▼2.68
Aotomot Gallery /wp-admin/options-general.php?page=aotomot_gallery3.1937.60

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 27 new files
Database: no new tables, 2 new options
New WordPress options
aotomot_basics
aotomot_advanced

Browser metrics Passed 4 tests

This is an overview of browser requirements for Aotomot Gallery
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /4,043 ▲47118.12 ▲2.6013.35 ▲1.5564.55 ▲10.17
Dashboard /wp-admin3,190 ▲2598.29 ▲2.41221.21 ▲12.91150.77 ▼26.57
Posts /wp-admin/edit.php2,992 ▲2534.37 ▲1.6698.34 ▲12.91100.66 ▼26.21
Add New Post /wp-admin/post-new.php1,641 ▲5021.31 ▲2.57348.11 ▼104.73130.90 ▲14.55
Media Library /wp-admin/upload.php1,841 ▲314.92 ▼0.12124.49 ▼54.03120.28 ▼8.06
Aotomot Gallery /wp-admin/options-general.php?page=aotomot_gallery1,9414.19110.6678.39

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin did not uninstall successfully, leaving 2 options in the database
    • aotomot_basics
    • aotomot_advanced

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/aotomot-gallery/admin/partials/aotomot-gallery-admin-display.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: These screenshots require images: #1 (Create new gallery at Aotomot Platform https://aotomot.com/modules), #2 (Add new image to the gallery.), #3 (Configure basic settings in WordPess setting-> Aotomot Gallery), #4 (Configure advanced settings)
The official readme.txt might help

aotomot-gallery/aotomot-gallery.php 92% from 13 tests

Analyzing the main PHP file in "Aotomot Gallery" version 1.0.0
The following require your attention:
  • Domain Path: The domain path points to a folder that does not exist ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin1,096 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP14121736861
CSS206113
Sass1150103
JavaScript265719

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity10.50
▷ Minimum class complexity1.00
▷ Maximum class complexity69.00
Average method complexity2.19
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes10
▷ Abstract classes00.00%
▷ Concrete classes10100.00%
▷ Final classes00.00%
Methods63
▷ Static methods46.35%
▷ Public methods5892.06%
▷ Protected methods00.00%
▷ Private methods57.94%
Functions4
▷ Named functions375.00%
▷ Anonymous functions125.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
4 PNG files occupy 1.02MB with 0.73MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png57.90KB13.64KB▼ 76.44%
screenshot-2.png876.43KB224.81KB▼ 74.35%
screenshot-4.png32.57KB10.87KB▼ 66.63%
screenshot-3.png81.49KB27.66KB▼ 66.06%