78% cool-flickr-slideshow

Code Review | Cool Flickr Slideshow

WordPress plugin Cool Flickr Slideshow scored78%from 54 tests.

About plugin

  • Plugin page: cool-flickr-slide...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.8
  • WordPress version: 6.3.1
  • First release: Jul 28, 2012
  • Latest release: Dec 27, 2013
  • Number of updates: 37
  • Update frequency: every 14.0 days
  • Top authors: softy.5454 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /5,361 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼5.03ms] Passed 4 tests

An overview of server-side resources used by Cool Flickr Slideshow
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0241.15 ▼3.41
Dashboard /wp-admin3.33 ▲0.0247.98 ▼2.42
Posts /wp-admin/edit.php3.38 ▲0.0253.85 ▲4.60
Add New Post /wp-admin/post-new.php5.91 ▲0.0285.13 ▼18.87
Media Library /wp-admin/upload.php3.25 ▲0.0238.38 ▲5.54
Cool Flickr Slideshow /wp-admin/admin.php?page=flickr-gallery-overview3.2132.68
Flickr Settings /wp-admin/admin.php?page=flickr-gallery-settings3.3033.20

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 11 new files
Database: 1 new table, 6 new options
New tables
wp_flicker_types
New WordPress options
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Cool Flickr Slideshow
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,826 ▲8013.30 ▼1.084.86 ▲3.1642.46 ▲0.16
Dashboard /wp-admin2,229 ▲415.99 ▲1.12104.19 ▼2.7775.18 ▲27.94
Posts /wp-admin/edit.php2,115 ▲261.98 ▼0.0435.76 ▼3.9232.68 ▼4.53
Add New Post /wp-admin/post-new.php1,536 ▲2217.56 ▲0.07675.07 ▲29.0660.57 ▲3.56
Media Library /wp-admin/upload.php1,408 ▲204.14 ▼0.05100.85 ▼4.0781.14 ▲34.96
Cool Flickr Slideshow /wp-admin/admin.php?page=flickr-gallery-overview7972.0224.6927.47
Flickr Settings /wp-admin/admin.php?page=flickr-gallery-settings9291.7128.3226.90

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 were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=flickr-gallery-settings
    • > Notice in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php+32
    Undefined index: val
    • > GET request to /wp-admin/admin.php?page=flickr-gallery-settings
    • > Notice in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php+40
    Undefined index: flickr-gallery_hidden
    • > GET request to /wp-admin/admin.php?page=flickr-gallery-settings
    • > Notice in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php+166
    Undefined variable: flickr_uid
    • > GET request to /wp-admin/admin.php?page=flickr-gallery-settings
    • > Notice in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php+170
    Undefined variable: flickr_api
    • > GET request to /wp-admin/admin.php?page=flickr-gallery-settings
    • > Notice in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php+174
    Undefined variable: flickr_groupid
    • > GET request to /wp-admin/admin.php?page=flickr-gallery-settings
    • > Notice in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php+179
    Undefined variable: flickr_set
    • > GET request to /wp-admin/admin.php?page=flickr-gallery-settings
    • > Notice in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php+185
    Undefined variable: flickr_width
    • > GET request to /wp-admin/admin.php?page=flickr-gallery-settings
    • > Notice in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php+186
    Undefined variable: flickr_height

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 fix the following items
  • 6× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Notice
      Undefined index: val in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php on line 32
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_add.php:29
    • > PHP Notice
      Undefined index: flickr-gallery_hidden in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php on line 40
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/cool-flickr-slideshow/cool-flickr-slideshow.php:13
    • > PHP Notice
      Undefined index: flickr-gallery_add_hidden in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_add.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/cool-flickr-slideshow/flickr_gallery_admin.php:146

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: Add images for these screenshots: #1 (Flickr slideshows settings page.), #2 (Slideshow (main view))
You can look at the official readme.txt

cool-flickr-slideshow/cool-flickr-slideshow.php Passed 13 tests

The principal PHP file in "Cool Flickr Slideshow" v. 1.0 is loaded by WordPress automatically on each request
66 characters long description:
Creates beautiful flickr slideshows from Set,API,User ID or Group.

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 detected367 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP42432367

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
3 PNG files occupy 0.44MB with 0.42MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/flickr-icon.png50.91KB0.76KB▼ 98.51%
banner-772x250.png202.25KB17.94KB▼ 91.13%
assets/banner-772x250.png202.25KB17.94KB▼ 91.13%