84% dpiordie

Code Review | DPIorDIE

WordPress plugin DPIorDIE scored 84% from 54 tests.

About plugin

  • Plugin page: dpiordie
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-5.2
  • WordPress version: 6.3.1
  • First release: May 16, 2019
  • Latest release: May 16, 2019
  • Number of updates: 5
  • Update frequency: every 2.0 days
  • Top authors: Halsys (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 570 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▲0.11MB] [CPU: ▼4.17ms] Passed 4 tests

An overview of server-side resources used by DPIorDIE
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0444.38 ▼4.91
Dashboard /wp-admin3.44 ▲0.1351.42 ▼5.19
Posts /wp-admin/edit.php3.55 ▲0.1953.78 ▲0.34
Add New Post /wp-admin/post-new.php6.02 ▲0.1390.67 ▼5.53
Media Library /wp-admin/upload.php3.36 ▲0.1336.44 ▼1.03
DPIorDie /wp-admin/options-general.php?page=dpi-or-die3.3338.02

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for DPIorDIE
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲6913.20 ▼1.201.77 ▼0.0936.20 ▼17.17
Dashboard /wp-admin2,207 ▲195.83 ▼0.0798.59 ▼15.7838.47 ▼9.99
Posts /wp-admin/edit.php2,093 ▲42.03 ▼0.0237.15 ▲2.3533.78 ▼3.25
Add New Post /wp-admin/post-new.php1,537 ▲323.29 ▲0.18675.92 ▲31.7756.36 ▲2.84
Media Library /wp-admin/upload.php1,389 ▲14.25 ▲0.0695.96 ▼2.6841.21 ▲0.85
DPIorDie /wp-admin/options-general.php?page=dpi-or-die8962.1722.4141.19

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • 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
Everything seems fine, however this is by no means an exhaustive test

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
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/dpiordie/admin/views/admin.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: dropbox, die, max, upload, image...

dpiordie/index.php 85% from 13 tests

Analyzing the main PHP file in "DPIorDIE" version 1.0.1
It is important to fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Main file name: Name the main plugin file the same as the plugin slug ("dpiordie.php" instead of "index.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
No dangerous file extensions were detected749 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP6103312663
PO File1151786

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity25.00
▷ Minimum class complexity3.00
▷ Maximum class complexity47.00
Average method complexity2.41
▷ Minimum method complexity1.00
▷ Maximum method complexity16.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods34
▷ Static methods1647.06%
▷ Public methods3294.12%
▷ Protected methods00.00%
▷ Private methods25.88%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG images were found in this plugin