78% flickr-album-gallery

Code Review | Album Gallery - Flickr Album Gallery

WordPress plugin Album Gallery - Flickr Album Gallery scored78%from 54 tests.

About plugin

  • Plugin page: flickr-album-gallery
  • Plugin version: 2.2.13
  • PHP compatiblity: 4.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Aug 15, 2014
  • Latest release: Sep 6, 2023
  • Number of updates: 127
  • Update frequency: every 26.1 days
  • Top authors: FARAZFRANK (52.76%)weblizar (47.24%)wpshopmart (1.57%)

Code review

54 tests

User reviews

80 reviews

Install metrics

6,000+ active /362,686 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.15MB] [CPU: ▼7.55ms] 75% from 4 tests

Analyzing server-side resources used by Album Gallery - Flickr Album Gallery
The following require your attention
  • CPU: The total CPU usage must kept under 500.00ms (currently 503.88ms on /wp-admin/edit.php?post_type=fa_gallery&page=fag-getting-started)
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1138.46 ▲1.71
Dashboard /wp-admin3.48 ▲0.1450.79 ▼13.54
Posts /wp-admin/edit.php3.59 ▲0.2445.18 ▼1.30
Add New Post /wp-admin/post-new.php6.06 ▲0.1881.37 ▼12.99
Media Library /wp-admin/upload.php3.40 ▲0.1734.79 ▼2.36
Add New Album /wp-admin/post-new.php?post_type=fa_gallery3.4342.32
Upgrade To Pro /wp-admin/edit.php?post_type=fa_gallery&page=wpffag_products3.3956.82
Get New Slider Factory Plugin 1 /wp-admin/edit.php?post_type=fa_gallery&page=fag-getting-started3.55503.88
All Album Galleries /wp-admin/edit.php?post_type=fa_gallery3.4436.61

Server storage [IO: ▲2.26MB] [DB: ▲0.03MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 43 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
widget_fa_gallery
widget_recent-comments
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for Album Gallery - Flickr Album Gallery
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,941 ▲19513.53 ▼1.155.46 ▲3.5642.96 ▼1.59
Dashboard /wp-admin2,246 ▲614.84 ▼1.0398.92 ▼4.9840.42 ▲0.29
Posts /wp-admin/edit.php2,126 ▲372.01 ▲0.0236.00 ▼4.8634.01 ▼2.04
Add New Post /wp-admin/post-new.php1,573 ▲5218.43 ▼4.88600.00 ▼69.2750.89 ▼0.28
Media Library /wp-admin/upload.php1,428 ▲404.27 ▼0.0194.25 ▼19.7842.26 ▼4.78
Add New Album /wp-admin/post-new.php?post_type=fa_gallery1,7312.5849.6653.31
Upgrade To Pro /wp-admin/edit.php?post_type=fa_gallery&page=wpffag_products8702.0224.2736.11
Get New Slider Factory Plugin 1 /wp-admin/edit.php?post_type=fa_gallery&page=fag-getting-started1,2581.9329.1947.03
All Album Galleries /wp-admin/edit.php?post_type=fa_gallery1,1661.9433.4436.06

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_fa_gallery
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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 perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/flickr-album-gallery/plugin-notice/admin/tabs/free-vs-pro-panel.php
  • 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/flickr-album-gallery/plugin-notice/admin/tabs/free-vs-pro-panel.php:141
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/flickr-album-gallery/plugin-notice/admin/getting-started.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function fag_call_plugin_api() in wp-content/plugins/flickr-album-gallery/plugin-notice/admin/tabs/getting-started-panel.php:24

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 Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
5 plugin tags: flickr widget, flickr album gallery, flickr gallery, flickr image gallery, flickr

flickr-album-gallery/flickr-album-gallery.php Passed 13 tests

The principal PHP file in "Album Gallery - Flickr Album Gallery" v. 2.2.13 is loaded by WordPress automatically on each request
103 characters long description:
Flickr Album Gallery is on JS API plugin to display all public Flickr albums on your WordPress website.

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
Everything looks great! No dangerous files found in this plugin7,992 lines of code in 27 files:
LanguageFilesBlank linesComment linesLines of code
CSS7176186,342
PHP91201641,099
PO File3123138285
JavaScript63026255
SVG20011

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity13.25
▷ Minimum class complexity1.00
▷ Maximum class complexity24.00
Average method complexity3.23
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods22
▷ Static methods522.73%
▷ Public methods22100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
4 PNG files occupy 0.23MB with 0.03MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
plugin-notice/admin/images/Slider-Factory-Pro-features.png113.88KB111.79KB▼ 1.83%
img/play-pause.png0.59KB0.46KB▼ 22.77%
img/video-play.png2.75KB1.80KB▼ 34.51%
img/products/Slider-Factory-Pro.png113.88KB111.79KB▼ 1.83%