10% is-circular-photo-gallery

Code Review | IS Circular Photo Gallery

WordPress plugin IS Circular Photo Gallery scored10%from 54 tests.

About plugin

  • Plugin page: is-circular-photo...
  • Plugin version: 1.9
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.5.1
  • WordPress version: 6.3.1
  • First release: Sep 12, 2013
  • Latest release: Jan 14, 2014
  • Number of updates: 22
  • Update frequency: every 5.8 days
  • Top authors: Irena0575 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /5,893 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
These installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/is-circular-photo-gallery/wp-iscircularphoto.php+32
    Methods with the same name as their class will not be constructors in a future version of PHP; ISCPGallery has a deprecated constructor

Server metrics [RAM: ▼1.71MB] [CPU: ▼49.83ms] Passed 4 tests

Server-side resources used by IS Circular Photo Gallery
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.28 ▼1.195.63 ▼35.75
Dashboard /wp-admin2.30 ▼1.018.99 ▼39.04
Posts /wp-admin/edit.php2.30 ▼1.067.34 ▼43.81
Add New Post /wp-admin/post-new.php2.30 ▼3.596.18 ▼80.71
Media Library /wp-admin/upload.php2.30 ▼0.935.86 ▼29.52
WP-IS Circular Photo Gallery /wp-admin/options-general.php?page=wpISCircularPhoto2.305.99

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for IS Circular Photo Gallery
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,918 ▲16113.95 ▼0.425.79 ▲3.7842.17 ▼6.20
Dashboard /wp-admin2,212 ▲245.86 ▼0.02106.99 ▼9.6644.26 ▼0.24
Posts /wp-admin/edit.php2,095 ▲31.99 ▼0.0340.55 ▲3.6134.69 ▼1.62
Add New Post /wp-admin/post-new.php1,533 ▲1123.34 ▲0.21663.70 ▼20.4852.81 ▼9.91
Media Library /wp-admin/upload.php1,391 ▲34.23 ▼0.0099.78 ▼1.3441.47 ▼2.08
WP-IS Circular Photo Gallery /wp-admin/options-general.php?page=wpISCircularPhoto1,1732.0622.7334.77

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The plugin did not uninstall gracefully
    • > Deprecated in wp-content/plugins/is-circular-photo-gallery/wp-iscircularphoto.php+32
    Methods with the same name as their class will not be constructors in a future version of PHP; ISCPGallery has a deprecated constructor
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=wpISCircularPhoto
    • > Deprecated in wp-content/plugins/is-circular-photo-gallery/wp-iscircularphoto.php+32
    Methods with the same name as their class will not be constructors in a future version of PHP; ISCPGallery has a deprecated constructor

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
Almost there! Just fix the following items
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/is-circular-photo-gallery/wp-iscircularphoto.php:54
    • > PHP Fatal error
      Uncaught Error: Call to undefined function delete_option() in wp-content/plugins/is-circular-photo-gallery/uninstall.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Screenshots: Add images for these screenshots: #1 (IS Circular Photo Gallery, captions enabled), #2 (IS Circular Photo Gallery, captions disabled), #3 (Choose the options you need), #4 (IS Circular Photo Gallery, Large picture width = Container width CSS (640 px); Large picture height = Container height (480px); captions enabled.)
  • Tags: There are too many tags (17 tag instead of maximum 10)
Please take inspiration from this readme.txt

is-circular-photo-gallery/wp-iscircularphoto.php 92% from 13 tests

Analyzing the main PHP file in "IS Circular Photo Gallery" version 1.9
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("is-circular-photo-gallery.php" instead of "wp-iscircularphoto.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected1,840 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript24021431,069
PHP2151160633
CSS1193138

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity80.00
▷ Minimum class complexity80.00
▷ Maximum class complexity80.00
Average method complexity7.08
▷ Minimum method complexity1.00
▷ Maximum method complexity33.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods13
▷ Static methods00.00%
▷ Public methods13100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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
6 PNG files occupy 0.79MB with 0.46MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/sliderblack.png0.24KB0.13KB▼ 47.77%
screenshot-2.png161.31KB54.67KB▼ 66.11%
screenshot-4.png443.98KB165.50KB▼ 62.72%
img/slider.png0.24KB0.13KB▼ 48.40%
screenshot-1.png155.91KB52.87KB▼ 66.09%