74% prodibi-photo-library

Code Review | Prodibi Photo Library

WordPress plugin Prodibi Photo Library scored74%from 54 tests.

About plugin

  • Plugin page: prodibi-photo-lib...
  • Plugin version: 2.0.2
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.1.1
  • WordPress version: 6.3.1
  • First release: Feb 12, 2018
  • Latest release: Apr 10, 2019
  • Number of updates: 19
  • Update frequency: every 22.3 days
  • Top authors: prodibi (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /3,033 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▼1.90MB] [CPU: ▼51.15ms] Passed 4 tests

A check of server-side resources used by Prodibi Photo Library
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.09 ▼1.374.43 ▼40.33
Dashboard /wp-admin2.11 ▼1.206.30 ▼40.18
Posts /wp-admin/edit.php2.11 ▼1.255.78 ▼40.23
Add New Post /wp-admin/post-new.php2.11 ▼3.786.06 ▼83.86
Media Library /wp-admin/upload.php2.11 ▼1.126.77 ▼25.13

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Prodibi Photo Library
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,856 ▲11013.36 ▼1.025.56 ▲3.7342.88 ▼0.11
Dashboard /wp-admin2,224 ▲365.82 ▼0.0598.94 ▼6.3182.94 ▲40.87
Posts /wp-admin/edit.php2,107 ▲212.04 ▲0.0543.48 ▲6.8140.87 ▲9.01
Add New Post /wp-admin/post-new.php6,256 ▲4,71320.87 ▲2.45901.94 ▲301.6338.73 ▼12.11
Media Library /wp-admin/upload.php1,400 ▲154.24 ▼0.02113.68 ▲7.2879.96 ▲33.28

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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
  • Uninstall procedure had uncaught errors
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the prodibi-script handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/prodibi-photo-library/prodibi.php:126

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
5 plugin tags: performance, photos, images, gallery, responsive gallery

prodibi-photo-library/prodibi.php 92% from 13 tests

The primary PHP file in "Prodibi Photo Library" version 2.0.2 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("prodibi-photo-library.php" instead of "prodibi.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin165 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP17011165

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity16.00
▷ Minimum class complexity16.00
▷ Maximum class complexity16.00
Average method complexity2.07
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods14
▷ Static methods00.00%
▷ Public methods14100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
No PNG images were found in this plugin