89% duggmedia

Code Review | DuggMedia

WordPress plugin DuggMedia scored89%from 54 tests.

About plugin

  • Plugin page: duggmedia
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-5.4.2
  • WordPress version: 6.3.1
  • First release: Jun 14, 2020
  • Latest release: Jun 14, 2020
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: duggmedia (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /429 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼6.51ms] Passed 4 tests

Server-side resources used by DuggMedia
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0358.83 ▲16.84
Dashboard /wp-admin3.33 ▲0.0347.85 ▼6.25
Posts /wp-admin/edit.php3.45 ▲0.0946.71 ▼1.56
Add New Post /wp-admin/post-new.php5.91 ▲0.0386.79 ▼21.44
Media Library /wp-admin/upload.php3.26 ▲0.0336.78 ▲3.21
DuggMedia /wp-admin/options-general.php?page=duggmedia_settings3.2436.98

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 19 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
db_upgraded
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
duggmedia_version
theysaidso_admin_options

Browser metrics Passed 4 tests

DuggMedia: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,795 ▲3414.34 ▼0.252.63 ▲0.8656.98 ▲13.82
Dashboard /wp-admin2,204 ▲275.61 ▲0.0384.51 ▼10.1943.36 ▼0.26
Posts /wp-admin/edit.php2,103 ▼21.98 ▼0.0137.60 ▲0.4835.67 ▲2.12
Add New Post /wp-admin/post-new.php1,531 ▼523.42 ▲0.25644.84 ▼45.9062.47 ▲12.53
Media Library /wp-admin/upload.php1,406 ▲64.19 ▼0.0399.66 ▼4.6544.19 ▼5.91
DuggMedia /wp-admin/options-general.php?page=duggmedia_settings9991.9923.5530.08

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
  • Zombie WordPress options were found after uninstall: 7 options
    • duggmedia_version
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 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 SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 93% 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
8 plugin tags: store, photo, share, webshop, duggonline...

duggmedia/duggmedia.php 85% from 13 tests

The entry point to "DuggMedia" version 1.0.0 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 184 characters long)
  • Requires at least: The required version number must match the one declared in readme.txt ("4.6" instead of "5.2")

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
Good job! No executable or dangerous file extensions detected261 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP45344248
CSS11013

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity3.50
▷ Minimum class complexity3.00
▷ Maximum class complexity4.00
Average method complexity1.29
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods17
▷ Static methods423.53%
▷ Public methods1270.59%
▷ Protected methods00.00%
▷ Private methods529.41%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
4 PNG files occupy 0.40MB with 0.24MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
static/duggmedia-logo.png158.52KB58.31KB▼ 63.21%
admin/static/duggmedia-logo.png158.52KB58.31KB▼ 63.21%
admin/static/duggmedia-support-button.png44.41KB18.88KB▼ 57.49%
static/duggmedia-support-button.png44.41KB18.88KB▼ 57.49%