84% photospace-responsive

Code Review | Photospace Responsive Gallery

WordPress plugin Photospace Responsive Gallery scored84%from 54 tests.

About plugin

  • Plugin page: photospace-respon...
  • Plugin version: 2.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Mar 11, 2013
  • Latest release: Sep 13, 2023
  • Number of updates: 62
  • Update frequency: every 62.0 days
  • Top authors: deanoakley (100%)

Code review

54 tests

User reviews

11 reviews

Install metrics

1,000+ active /41,167 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.27MB] [CPU: ▼6.11ms] Passed 4 tests

An overview of server-side resources used by Photospace Responsive Gallery
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.72 ▲0.2541.12 ▼2.28
Dashboard /wp-admin3.58 ▲0.2748.13 ▼6.13
Posts /wp-admin/edit.php3.69 ▲0.3352.73 ▲5.01
Add New Post /wp-admin/post-new.php6.18 ▲0.2987.17 ▼15.62
Media Library /wp-admin/upload.php3.50 ▲0.2736.29 ▼0.42
Photospace Res Settings /wp-admin/options-general.php?page=photospace_responsive_gallery_settings3.5145.03

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 36 new files
Database: no new tables, 7 new options
New WordPress options
photospace_responsive_gallery_version
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Photospace Responsive Gallery
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,900 ▲16513.97 ▼0.6510.74 ▲9.0745.69 ▼0.26
Dashboard /wp-admin2,211 ▲265.83 ▼0.07104.55 ▼0.7940.42 ▼2.03
Posts /wp-admin/edit.php2,100 ▲82.02 ▲0.0039.01 ▲0.0035.21 ▲2.25
Add New Post /wp-admin/post-new.php1,521 ▼2123.26 ▲5.22654.93 ▲26.0052.38 ▲3.14
Media Library /wp-admin/upload.php1,396 ▲54.23 ▲0.0296.05 ▼4.0942.07 ▼2.40
Photospace Res Settings /wp-admin/options-general.php?page=photospace_responsive_gallery_settings1,2343.0344.9324.36

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 7 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • photospace_responsive_gallery_version
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/photospace-responsive/includes/photospace-responsive-wp-headers.php:3

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 88% from 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
Please fix the following attributes:
  • Screenshots: Add images for these screenshots: #1 (Screenshot Default gallery layout), #2 (Screenshot Admin Area)
  • Tags: There are too many tags (14 tag instead of maximum 10)
The official readme.txt is a good inspiration

photospace-responsive/photospace-responsive.php Passed 13 tests

"Photospace Responsive Gallery" version 2.2.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
140 characters long description:
A simplified version of Photospace featuring a responsive only layout. This is a image gallery plugin for WordPress built using Galleriffic.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected7,473 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
JSON2005,194
PHP93356331,119
JavaScript11220225937
LESS120204
SVG20218
CSS1001

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity26.80
▷ Minimum class complexity5.00
▷ Maximum class complexity66.00
Average method complexity4.00
▷ Minimum method complexity1.00
▷ Maximum method complexity48.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods43
▷ Static methods24.65%
▷ Public methods4093.02%
▷ Protected methods00.00%
▷ Private methods36.98%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
plugin-assets/images/arrow-left.png0.25KB0.21KB▼ 16.60%
plugin-assets/images/arrow-right.png0.25KB0.21KB▼ 15.50%