10% wp-pgp-email

Code Review | WP PGP email

WordPress plugin WP PGP email scored10%from 54 tests.

About plugin

  • Plugin page: wp-pgp-email
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4.0-4.2.1
  • WordPress version: 6.3.1
  • First release: May 14, 2015
  • Latest release: May 14, 2015
  • Number of updates: 5
  • Update frequency: every 2.4 days
  • Top authors: invisnet (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /736 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The following installer errors require your attention
  • The plugin cannot be installed
    • > Compile error in wp-content/plugins/wp-pgp-email/encrypt.php+9
    Cannot redeclare wp_mail() (previously declared in wp-includes/pluggable.php:174)

Server metrics [RAM: ▲0.00MB] [CPU: ▼5.58ms] Passed 4 tests

Server-side resources used by WP PGP email
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0047.48 ▲5.46
Dashboard /wp-admin3.31 ▲0.0050.98 ▼2.90
Posts /wp-admin/edit.php3.36 ▲0.0052.93 ▼0.95
Add New Post /wp-admin/post-new.php5.89 ▲0.0089.25 ▼17.81
Media Library /wp-admin/upload.php3.23 ▲0.0037.99 ▼0.64

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 14 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP PGP email
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.72 ▲0.342.09 ▲0.3240.33 ▼2.24
Dashboard /wp-admin2,192 ▲125.61 ▼0.0186.09 ▼4.0443.83 ▼0.26
Posts /wp-admin/edit.php2,097 ▼31.97 ▼0.0435.56 ▼0.8336.26 ▼2.91
Add New Post /wp-admin/post-new.php1,526 ▼223.21 ▲0.33664.64 ▼78.2672.02 ▲11.04
Media Library /wp-admin/upload.php1,403 ▲34.12 ▼0.06102.95 ▼10.0744.67 ▼8.13

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options

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
Good news, no errors were detected

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

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)
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that need to be fixed:
  • Screenshots: Please add an image for screenshot #1 (User profile page.)
You can take inspiration from this readme.txt

wp-pgp-email/wp-pgp-email.php Passed 13 tests

Analyzing the main PHP file in "WP PGP email" version 0.1
54 characters long description:
Provides mechanism to encrypt outgoing email using PGP

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected1,232 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
PHP112351471,208
Markdown115024

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity16.43
▷ Minimum class complexity1.00
▷ Maximum class complexity32.00
Average method complexity4.72
▷ Minimum method complexity1.00
▷ Maximum method complexity28.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods29
▷ Static methods1448.28%
▷ Public methods2482.76%
▷ Protected methods00.00%
▷ Private methods517.24%
Functions15
▷ Named functions15100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png13.28KB7.79KB▼ 41.32%