77% wp-flickrshow

Code Review | Flickr Show

WordPress plugin Flickr Show scored77%from 54 tests.

About plugin

  • Plugin page: wp-flickrshow
  • Plugin version: 1.5
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Feb 17, 2012
  • Latest release: May 16, 2012
  • Number of updates: 22
  • Update frequency: every 4.1 days
  • Top authors: nuvuscripts (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /4,740 total downloads

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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.09MB] [CPU: ▼1.35ms] Passed 4 tests

This is a short check of server-side resources used by Flickr Show
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0950.59 ▲9.95
Dashboard /wp-admin3.40 ▲0.0949.29 ▲0.82
Posts /wp-admin/edit.php3.45 ▲0.0947.27 ▼3.44
Add New Post /wp-admin/post-new.php5.98 ▲0.0985.58 ▼9.93
Media Library /wp-admin/upload.php3.32 ▲0.0940.15 ▲7.14
FlickrShow Settings /wp-admin/options-general.php?page=fsplugin3.2730.26

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 24 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
widget_widget_flickrshow
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Flickr Show
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,994 ▲25913.77 ▼0.9014.51 ▲13.0536.65 ▼12.41
Dashboard /wp-admin2,210 ▲194.85 ▼0.25101.95 ▼5.6736.00 ▼5.15
Posts /wp-admin/edit.php2,093 ▲12.04 ▼0.0134.50 ▼6.2930.42 ▼5.70
Add New Post /wp-admin/post-new.php1,517 ▼1617.82 ▼4.99613.11 ▼39.7152.85 ▼1.47
Media Library /wp-admin/upload.php1,392 ▲14.20 ▲0.0593.45 ▼23.9842.89 ▼6.46
FlickrShow Settings /wp-admin/options-general.php?page=fsplugin8432.0126.4928.44

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • widget_widget_flickrshow
    • can_compress_scripts

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
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=fsplugin
    • > Notice in wp-content/plugins/wp-flickrshow/flickrshow.php+107
    Trying to access array offset on value of type bool

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
  • 16× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Notice
      Trying to access array offset on value of type bool in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/phpFlickr.php on line 302
    • > PHP Notice
      unserialize(): Error at offset 0 of 169 bytes in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/phpFlickr.php on line 301
    • > PHP Notice
      Trying to access array offset on value of type bool in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/example.php on line 20
    • > PHP Warning
      fclose() expects parameter 1 to be resource, bool given in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/phpFlickr.php on line 187
    • > PHP Warning
      fwrite() expects parameter 1 to be resource, bool given in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/phpFlickr.php on line 186
    • > PHP Warning
      fopen(/6a79f8ddeea35f2acc03cb46768bc8a0.cache): failed to open stream: Permission denied in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/phpFlickr.php on line 185
    • > PHP Notice
      Trying to access array offset on value of type bool in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/example.php on line 22
    • > PHP Parse error
      syntax error, unexpected 'unset' (T_UNSET) in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/auth.php on line 17
    • > PHP Notice
      Trying to access array offset on value of type bool in wp-content/plugins/wp-flickrshow/phpFlickr-3.1/phpFlickr.php on line 302
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-flickrshow/flickrshow.php:33

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 81% 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
Attributes that require attention:
  • Screenshots: These screenshots do not have images: #1 (/trunk/screenshots/screenshot-1.png), #2 (/trunk/screenshots/screenshot-2.png), #3 (/trunk/screenshots/screenshot-3.png), #4 (/trunk/screenshots/screenshot-4.png), #5 (/trunk/screenshots/screenshot-5.png), #6 (/trunk/screenshots/screenshot-6.png)
  • Requires at least: Version format is invalid
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === wp-flickrshow === )
Please take inspiration from this readme.txt

wp-flickrshow/flickrshow.php 92% from 13 tests

The main file in "Flickr Show" v. 1.5 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wp-flickrshow.php" instead of "flickrshow.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 detected2,676 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP54434051,719
CSS19240526
JavaScript219065431

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity74.00
▷ Minimum class complexity13.00
▷ Maximum class complexity184.00
Average method complexity2.07
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods204
▷ Static methods00.00%
▷ Public methods204100.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 50% from 2 tests

Image compression 50% from 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
14 PNG files occupy 4.30MB with 2.99MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshots/screenshot-5.png628.31KB231.16KB▼ 63.21%
prel.png59.21KB3.58KB▼ 93.96%
adminlogo.png65.06KB29.58KB▼ 54.54%
arrows2.png40.73KB10.83KB▼ 73.40%
limage.png129.49KB48.34KB▼ 62.67%