84% meks-simple-flickr-widget

Code Review | Meks Simple Flickr Widget

WordPress plugin Meks Simple Flickr Widget scored84%from 54 tests.

About plugin

  • Plugin page: meks-simple-flick...
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-6.3
  • WordPress version: 6.3.1
  • First release: Jan 10, 2014
  • Latest release: Sep 11, 2023
  • Number of updates: 42
  • Update frequency: every 84.1 days
  • Top authors: mekshq (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

30,000+ active /350,091 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼10.30ms] Passed 4 tests

Analyzing server-side resources used by Meks Simple Flickr Widget
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0543.27 ▲0.44
Dashboard /wp-admin3.35 ▲0.0151.78 ▼20.27
Posts /wp-admin/edit.php3.40 ▲0.0547.38 ▼1.87
Add New Post /wp-admin/post-new.php5.93 ▲0.0594.90 ▼7.95
Media Library /wp-admin/upload.php3.27 ▲0.0538.44 ▼11.11

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Meks Simple Flickr Widget
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲3313.27 ▼0.972.03 ▼0.0743.32 ▲2.92
Dashboard /wp-admin2,226 ▲195.87 ▲0.9196.58 ▼14.3338.77 ▲1.47
Posts /wp-admin/edit.php2,102 ▲22.04 ▲0.0735.65 ▼1.3037.47 ▲4.27
Add New Post /wp-admin/post-new.php1,542 ▲1622.96 ▲5.23615.01 ▼40.1475.65 ▲13.86
Media Library /wp-admin/upload.php1,402 ▲24.22 ▲0.06114.45 ▼7.9249.86 ▼2.70

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • widget_mks_flickr_widget
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Please fix the following items
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/meks-simple-flickr-widget/inc/class-flickr-widget.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function trailingslashit() in wp-content/plugins/meks-simple-flickr-widget/meks-simple-flickr-widget.php:31

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: flickr, photostream, photos, widget, sidebar

meks-simple-flickr-widget/meks-simple-flickr-widget.php Passed 13 tests

Analyzing the main PHP file in "Meks Simple Flickr Widget" version 1.3
114 characters long description:
Quickly display your Flickr photos inside WordPress widget. No authorization required (only provide your user id).

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin198 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP24631138
PO File1111136
CSS11024

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.13
Average class complexity13.00
▷ Minimum class complexity13.00
▷ Maximum class complexity13.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
There are no PNG files in this plugin