Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors
Server metrics [RAM: ▼0.18MB] [CPU: ▼9.79ms] Passed 4 tests
An overview of server-side resources used by Photoswipe for NextGEN Gallery
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.73 ▼0.73 | 13.25 ▼32.75 |
Dashboard /wp-admin | 3.31 ▲0.01 | 45.64 ▼3.15 |
Posts /wp-admin/edit.php | 3.36 ▲0.01 | 49.23 ▲2.39 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.01 | 93.03 ▼2.67 |
Media Library /wp-admin/upload.php | 3.23 ▲0.01 | 36.34 ▼0.58 |
Photoswipe /wp-admin/admin.php?page=photoswipe-for-nextgen-gallery/ngg-photoswipe.php | 3.18 | 28.06 |
Server storage [IO: ▲0.76MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 15 new files
Database: no new tables, 8 new options
New WordPress options |
---|
widget_theysaidso_widget |
nggphotoswipe_enabled |
db_upgraded |
can_compress_scripts |
additional_viewers |
theysaidso_admin_options |
widget_recent-posts |
widget_recent-comments |
Browser metrics Passed 4 tests
An overview of browser requirements for Photoswipe for NextGEN Gallery
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,800 ▲65 | 14.74 ▲0.37 | 1.76 ▼0.14 | 44.06 ▼2.75 |
Dashboard /wp-admin | 2,206 ▲14 | 4.85 ▼0.03 | 108.38 ▼3.34 | 43.98 ▼6.97 |
Posts /wp-admin/edit.php | 2,089 ▼0 | 2.04 ▲0.05 | 39.97 ▲3.78 | 35.77 ▲3.71 |
Add New Post /wp-admin/post-new.php | 1,514 ▼9 | 17.87 ▼5.32 | 658.39 ▼25.53 | 56.90 ▲0.47 |
Media Library /wp-admin/upload.php | 1,382 ▼6 | 4.20 ▼0.02 | 95.86 ▲3.15 | 43.08 ▼3.73 |
Photoswipe /wp-admin/admin.php?page=photoswipe-for-nextgen-gallery/ngg-photoswipe.php | 836 | 2.05 | 25.30 | 27.15 |
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
It is recommended to fix the following
- Zombie WordPress options detected upon uninstall: 6 options
- widget_recent-posts
- theysaidso_admin_options
- widget_theysaidso_widget
- can_compress_scripts
- widget_recent-comments
- db_upgraded
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Smoke test failed, please fix the following
- > GET request to /wp-admin/admin.php?page=photoswipe-for-nextgen-gallery/ngg-photoswipe.php
- > Notice in wp-content/plugins/photoswipe-for-nextgen-gallery/ngg-photoswipe.php+73
Undefined index: nggphotoswipe_enabled
- > GET request to /wp-admin/admin.php?page=photoswipe-for-nextgen-gallery/ngg-photoswipe.php
- > Notice in wp-content/plugins/photoswipe-for-nextgen-gallery/ngg-photoswipe.php+77
Undefined index: additional_viewers
- > GET request to /wp-admin/admin.php?page=photoswipe-for-nextgen-gallery/ngg-photoswipe.php
- > Warning in wp-content/plugins/photoswipe-for-nextgen-gallery/ngg-photoswipe.php+95
Illegal string offset 'fancybox'
- > GET request to /wp-admin/admin.php?page=photoswipe-for-nextgen-gallery/ngg-photoswipe.php
- > Notice in wp-content/plugins/photoswipe-for-nextgen-gallery/ngg-photoswipe.php+95
Uninitialized string offset: 0
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
- 1× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/photoswipe-for-nextgen-gallery/ngg-photoswipe.php:48
- > PHP Fatal error
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
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
- Screenshots: These screenshots require images: #1 (Plugin options - Choose when Photoswipe should be applied.), #2 (New Gallery submenu), #3 (Result)
photoswipe-for-nextgen-gallery/ngg-photoswipe.php 92% from 13 tests
"Photoswipe for NextGEN Gallery" version 1.2.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
- Main file name: Name the main plugin file the same as the plugin slug ("photoswipe-for-nextgen-gallery.php" instead of "ngg-photoswipe.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected418 lines of code in 6 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 4 | 2 | 17 | 187 |
CSS | 1 | 31 | 18 | 154 |
PHP | 1 | 18 | 22 | 77 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.38 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 5 | |
▷ Named functions | 5 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
5 PNG files occupy 0.66MB with 0.34MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
lib/photoswipe/images/icons@2x.png | 9.19KB | 5.50KB | ▼ 40.21% |
screenshot-2.png | 6.86KB | 3.77KB | ▼ 45.00% |
screenshot-1.png | 15.42KB | 6.28KB | ▼ 59.26% |
lib/photoswipe/images/icons.png | 5.84KB | 3.80KB | ▼ 35.05% |
screenshot-3.png | 637.47KB | 131.41KB | ▼ 79.39% |