10% bmre-domain-monitor

Code Review | BMRE Domain Monitor

WordPress plugin BMRE Domain Monitor scored10%from 54 tests.

About plugin

  • Plugin page: bmre-domain-monitor
  • Plugin version: 0.9.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.7.1
  • WordPress version: 6.3.1
  • First release: Oct 5, 2012
  • Latest release: Nov 4, 2013
  • Number of updates: 44
  • Update frequency: every 9.0 days
  • Top authors: dvwallin (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,886 total downloads

Benchmarks

Plugin footprint 23% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
These installer errors require your attention
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/bmre-domain-monitor/lib/whois.main.php+31
    Methods with the same name as their class will not be constructors in a future version of PHP; Whois has a deprecated constructor

Server metrics [RAM: ▼1.80MB] [CPU: ▼56.39ms] Passed 4 tests

Server-side resources used by BMRE Domain Monitor
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.19 ▼1.275.61 ▼34.45
Dashboard /wp-admin2.21 ▼1.096.51 ▼42.19
Posts /wp-admin/edit.php2.21 ▼1.156.44 ▼47.21
Add New Post /wp-admin/post-new.php2.21 ▼3.686.06 ▼101.69
Media Library /wp-admin/upload.php2.21 ▼1.027.71 ▼25.33
BMRE Domain Monitor /wp-admin/options-general.php?page=bmre_domain_monitor2.215.56

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 127 new files
Database: 3 new tables, 7 new options
New tables
wp_bmre_domain_monitor
wp_bmre_domain_monitor_domain_checker
wp_bmre_domain_monitor_settings
New WordPress options
widget_theysaidso_widget
widget_recent-comments
db_upgraded
bmre_domain_monitor_db_version
theysaidso_admin_options
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

BMRE Domain Monitor: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,801 ▲4014.72 ▲0.431.80 ▲0.2643.69 ▲0.77
Dashboard /wp-admin2,204 ▲335.55 ▼0.0296.80 ▼8.9247.06 ▲8.60
Posts /wp-admin/edit.php2,109 ▲92.01 ▲0.0336.26 ▼3.5637.59 ▲2.51
Add New Post /wp-admin/post-new.php1,605 ▲6922.47 ▲4.34679.22 ▲65.4239.25 ▼36.81
Media Library /wp-admin/upload.php1,412 ▲124.19 ▲0.00109.41 ▼0.7651.71 ▲5.19
BMRE Domain Monitor /wp-admin/options-general.php?page=bmre_domain_monitor8532.0024.5831.68

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/bmre-domain-monitor/lib/whois.main.php+31
    Methods with the same name as their class will not be constructors in a future version of PHP; Whois has a deprecated constructor
  • Zombie tables detected upon uninstall: 3 tables
    • wp_bmre_domain_monitor_domain_checker
    • wp_bmre_domain_monitor
    • wp_bmre_domain_monitor_settings
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • bmre_domain_monitor_db_version
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 0% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=bmre_domain_monitor
    • > Deprecated in wp-content/plugins/bmre-domain-monitor/lib/whois.main.php+31
    Methods with the same name as their class will not be constructors in a future version of PHP; Whois has a deprecated constructor
    • > GET request to /wp-admin/options-general.php?page=bmre_domain_monitor
    • > Deprecated in wp-content/plugins/bmre-domain-monitor/lib/whois.client.php+30
    Methods with the same name as their class will not be constructors in a future version of PHP; WhoisClient has a deprecated constructor
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=bmre_domain_monitor
    • > Deprecated in wp-content/plugins/bmre-domain-monitor/lib/whois.idna.php+935
    Array and string offset access syntax with curly braces is deprecated
    • > GET request to /wp-admin/options-general.php?page=bmre_domain_monitor
    • > Deprecated in wp-content/plugins/bmre-domain-monitor/lib/whois.idna.php+54
    Methods with the same name as their class will not be constructors in a future version of PHP; idna_convert has a deprecated constructor

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/bmre-domain-monitor/lib/whois.cl.php
  • 9× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Cannot use string offset as an array in wp-content/plugins/bmre-domain-monitor/lib/whois.parser.php:350
    • > PHP Fatal error
      Uncaught Error: Class 'WhoisClient' not found in wp-content/plugins/bmre-domain-monitor/lib/whois.gtld.php:33
    • > PHP Fatal error
      Uncaught Error: Class 'Whois' not found in wp-content/plugins/bmre-domain-monitor/lib/whois.utils.php:28
    • > PHP Fatal error
      Uncaught Error: Class 'WhoisClient' not found in wp-content/plugins/bmre-domain-monitor/lib/whois.ws.php:33
    • > PHP Warning
      Illegal string offset 'disclaimer' in wp-content/plugins/bmre-domain-monitor/lib/whois.parser.php on line 350
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/bmre-domain-monitor/lib/whois.servers.php:32
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_bloginfo() in wp-content/plugins/bmre-domain-monitor/bmre_domain_monitor.php:28
    • > PHP Fatal error
      Uncaught Error: Class 'WhoisClient' not found in wp-content/plugins/bmre-domain-monitor/lib/whois.ip.php:33
    • > PHP Fatal error
      Uncaught Error: Class 'WhoisClient' not found in wp-content/plugins/bmre-domain-monitor/lib/whois.jp.php:33

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
These are user-side errors you should fix
    • > GET request to /wp-admin/options-general.php?page=bmre_domain_monitor
    • > Network (severe)
    https://dwall.in/wp-content/uploads/2012/06/dwall-reg.png - Failed to load resource: net::ERR_CERT_COMMON_NAME_INVALID

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
3 plugin tags: seo, domain, monitor

bmre-domain-monitor/bmre_domain_monitor.php 92% from 13 tests

This is the main PHP file of "BMRE Domain Monitor" version 0.9.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("bmre-domain-monitor.php" instead of "bmre_domain_monitor.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin6,742 lines of code in 124 files:
LanguageFilesBlank linesComment linesLines of code
PHP1242,0262,6976,742

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity5.30
▷ Minimum class complexity1.00
▷ Maximum class complexity192.00
Average method complexity4.20
▷ Minimum method complexity1.00
▷ Maximum method complexity33.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes120
▷ Abstract classes00.00%
▷ Concrete classes120100.00%
▷ Final classes00.00%
Methods161
▷ Static methods00.00%
▷ Public methods161100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions22
▷ Named functions22100.00%
▷ Anonymous functions00.00%
Constants115
▷ Global constants115100.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 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
lib/whois.icon.png0.56KB0.49KB▼ 12.96%