94% global-smtp

Code Review | Global SMTP

WordPress plugin Global SMTP scored 94% from 54 tests.

About plugin

  • Plugin page: global-smtp
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-4.3
  • WordPress version: 5.8.1
  • First release: Sep 7, 2015
  • Latest release: Sep 7, 2015
  • Number of updates: 3
  • Update frequency: N/A
  • Top authors: alexander.rohmann (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

400+ active / 2,941 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.01MB] [CPU: ▼142.21ms] Passed 4 tests

Server-side resources used by Global SMTP
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.1335.79 ▲11.92
Dashboard /wp-admin3.07 ▲0.0248.34 ▼1.75
Posts /wp-admin/edit.php3.12 ▲0.0244.72 ▼1.08
Add New Post /wp-admin/post-new.php5.43 ▼0.0090.53 ▼565.27
Media Library /wp-admin/upload.php3.01 ▲0.0132.29 ▼0.73
Global SMTP Setup /wp-admin/options-general.php?page=global-smtp2.9828.26

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 4 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for Global SMTP
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,694 ▲9815.88 ▼0.138.75 ▼1.2146.47 ▲0.18
Dashboard /wp-admin2,975 ▲415.92 ▼0.30144.03 ▼15.98107.73 ▼3.69
Posts /wp-admin/edit.php2,744 ▲52.70 ▼0.0162.12 ▼16.3088.29 ▲1.63
Add New Post /wp-admin/post-new.php1,607 ▼818.75 ▼2.71383.24 ▲51.01112.81 ▲9.32
Media Library /wp-admin/upload.php1,812 ▲25.03 ▼0.01174.93 ▲19.56112.29 ▼1.83
Global SMTP Setup /wp-admin/options-general.php?page=global-smtp1,0812.2161.4970.63

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
This plugin's uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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 errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Error' not found in wp-content/plugins/global-smtp/global-smtp.php:190

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === global-smtp === )
Please take inspiration from this readme.txt

global-smtp/global-smtp.php Passed 13 tests

The primary PHP file in "Global SMTP" version 1.0 is used by WordPress to initiate all plugin functionality
64 characters long description:
Utility plugin to setup SMTP mail via constants in wp-config.php

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin213 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP15780152
Markdown119042
JSON10019

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity41.00
▷ Minimum class complexity41.00
▷ Maximum class complexity41.00
Average method complexity4.64
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods218.18%
▷ Public methods981.82%
▷ Protected methods218.18%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected