89% easy-dexter-lightbox

Code Review | Easy Dexter Lightbox

WordPress plugin Easy Dexter Lightbox scored89%from 54 tests.

About plugin

  • Plugin page: easy-dexter-lightbox
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2-4.9.4
  • WordPress version: 6.3.1
  • First release: Oct 19, 2017
  • Latest release: Feb 13, 2018
  • Number of updates: 3
  • Update frequency: every 38.7 days
  • Top authors: fristopher (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /610 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.04MB] [CPU: ▼6.53ms] Passed 4 tests

A check of server-side resources used by Easy Dexter Lightbox
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0024.52 ▼17.62
Dashboard /wp-admin3.36 ▲0.0545.12 ▼4.81
Posts /wp-admin/edit.php3.47 ▲0.1145.91 ▼1.69
Add New Post /wp-admin/post-new.php5.94 ▲0.0589.93 ▲1.44
Media Library /wp-admin/upload.php3.28 ▲0.0533.04 ▼1.99
Dexter Settings /wp-admin/options-general.php?page=dexter_settings3.2531.24

Server storage [IO: ▲0.11MB] [DB: ▲0.07MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 8 new options
New WordPress options
dexter_lightbox_settings
can_compress_scripts
dexter_theme_settings
widget_theysaidso_widget
db_upgraded
widget_recent-posts
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

Easy Dexter Lightbox: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,002 ▲26713.69 ▼0.699.04 ▲7.2939.95 ▼7.35
Dashboard /wp-admin2,210 ▲224.86 ▼1.04110.57 ▼7.9841.49 ▼4.95
Posts /wp-admin/edit.php2,093 ▲42.06 ▲0.0337.92 ▼0.4634.81 ▲2.50
Add New Post /wp-admin/post-new.php1,549 ▲1618.27 ▼4.95600.82 ▼21.9966.97 ▲13.53
Media Library /wp-admin/upload.php1,395 ▲104.34 ▲0.1193.58 ▼1.3040.89 ▼2.52
Dexter Settings /wp-admin/options-general.php?page=dexter_settings1,0361.7932.6226.75

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 8 options in the database
    • widget_recent-posts
    • db_upgraded
    • dexter_lightbox_settings
    • can_compress_scripts
    • dexter_theme_settings
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% 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:
  • Donate link: Invalid URI ("N/A")
  • Screenshots: Please add an image for screenshot #1 (None)
Please take inspiration from this readme.txt

easy-dexter-lightbox/plugin.php 92% from 13 tests

"Easy Dexter Lightbox" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("easy-dexter-lightbox.php" instead of "plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
There were no executable files found in this plugin1,822 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript273158762
PHP2145202564
CSS3830496

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity38.50
▷ Minimum class complexity32.00
▷ Maximum class complexity45.00
Average method complexity3.42
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods31
▷ Static methods00.00%
▷ Public methods31100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.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
PNG images were not found in this plugin