90% ohdear

Code Review | Oh Dear - Monitor Uptime, Performance and Broken Links

WordPress plugin Oh Dear - Monitor Uptime, Performance and Broken Links scored90%from 54 tests.

About plugin

  • Plugin page: ohdear
  • Plugin version: 1.0.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.1
  • WordPress version: 6.3.1
  • First release: Aug 6, 2020
  • Latest release: Nov 5, 2022
  • Number of updates: 7
  • Update frequency: every 118.2 days
  • Top authors: flowdee (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

40+ active /1,669 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 gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼1.48ms] Passed 4 tests

A check of server-side resources used by Oh Dear - Monitor Uptime, Performance and Broken Links
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0050.16 ▲4.09
Dashboard /wp-admin3.34 ▲0.0348.32 ▼2.79
Posts /wp-admin/edit.php3.39 ▲0.0352.30 ▲4.58
Add New Post /wp-admin/post-new.php5.92 ▲0.0388.79 ▼5.86
Media Library /wp-admin/upload.php3.26 ▲0.0336.16 ▼1.36
Dashboard /wp-admin/admin.php?page=ohdear3.0427.73
Settings /wp-admin/admin.php?page=ohdear-settings3.2329.57

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 22 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-comments
ohdear_settings
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Oh Dear - Monitor Uptime, Performance and Broken Links
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,841 ▲9513.94 ▼0.441.76 ▲0.0243.13 ▲2.38
Dashboard /wp-admin2,235 ▲505.98 ▲0.13111.60 ▲1.9187.58 ▲43.22
Posts /wp-admin/edit.php2,112 ▲201.97 ▼0.0435.02 ▼5.5433.32 ▼6.35
Add New Post /wp-admin/post-new.php1,536 ▲2323.07 ▲5.64688.43 ▼3.3257.93 ▲2.83
Media Library /wp-admin/upload.php1,405 ▲174.16 ▼0.04105.00 ▼2.1781.11 ▲35.35
Dashboard /wp-admin/admin.php?page=ohdear8882.4634.0828.66
Settings /wp-admin/admin.php?page=ohdear-settings8882.4835.0729.53

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-comments
    • ohdear_settings
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

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

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
4 plugin tags: performance, broken links, ohdear, uptime

ohdear/ohdear.php Passed 13 tests

The primary PHP file in "Oh Dear - Monitor Uptime, Performance and Broken Links" version 1.0.2 is used by WordPress to initiate all plugin functionality
105 characters long description:
This plugin brings Oh Dear uptime, performance and broken links monitoring into your WordPress dashboard.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin1,190 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP155205291,101
CSS116646
JavaScript291442
YAML1001

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.55
Average class complexity33.00
▷ Minimum class complexity1.00
▷ Maximum class complexity86.00
Average method complexity4.88
▷ Minimum method complexity1.00
▷ Maximum method complexity31.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes125.00%
Methods33
▷ Static methods26.06%
▷ Public methods2884.85%
▷ Protected methods00.00%
▷ Private methods515.15%
Functions21
▷ Named functions21100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/icon.png1.49KB1.26KB▼ 15.62%