73% pocketgecko-email

Code Review | PocketGecko Email

WordPress plugin PocketGecko Email scored73%from 54 tests.

About plugin

  • Plugin page: pocketgecko-email
  • Plugin version: 1.0.0
  • PHP compatiblity: +
  • PHP version: 7.4.16
  • WordPress compatibility: -5.7
  • WordPress version: 6.3.1
  • First release: Apr 1, 2021
  • Latest release: Apr 1, 2021
  • Number of updates: 4
  • Update frequency: every 0.3 days
  • Top authors: axiomattik (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /388 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.04MB] [CPU: ▼3.59ms] Passed 4 tests

An overview of server-side resources used by PocketGecko Email
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0337.65 ▲1.42
Dashboard /wp-admin3.36 ▲0.0148.66 ▼12.22
Posts /wp-admin/edit.php3.41 ▲0.0545.63 ▲0.66
Add New Post /wp-admin/post-new.php5.94 ▲0.0582.66 ▼4.12
Media Library /wp-admin/upload.php3.28 ▲0.0535.82 ▲1.32
Email /wp-admin/options-general.php?page=pgem_settings_menu3.2832.02

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 13 new files
Database: no new tables, 14 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
pgem_smtp_encryption_type
pgem_smtp_username
pgem_smtp_from_email
pgem_smtp_host
pgem_smtp_authentication
db_upgraded
pgem_smtp_password
pgem_smtp_from_name
...

Browser metrics Passed 4 tests

This is an overview of browser requirements for PocketGecko Email
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲6714.07 ▼0.332.04 ▲0.3644.96 ▲3.72
Dashboard /wp-admin2,204 ▲275.61 ▲0.0492.30 ▼10.6139.28 ▼1.92
Posts /wp-admin/edit.php2,106 ▲31.97 ▼0.0037.63 ▲2.6632.20 ▼0.36
Add New Post /wp-admin/post-new.php1,536 ▲1023.25 ▲0.28680.73 ▲31.8355.09 ▼8.30
Media Library /wp-admin/upload.php1,409 ▲94.16 ▼0.0498.48 ▼3.4644.27 ▲1.24
Email /wp-admin/options-general.php?page=pgem_settings_menu1,0572.0422.3731.85

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • Uninstall procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5905
    Function wpdb::prepare was called incorrectly. Unsupported value type (object). Please see Debugging in WordPress for more information. (This message was added in version 4.8.2.)
  • The uninstall procedure has failed, leaving 14 options in the database
    • pgem_smtp_host
    • widget_theysaidso_widget
    • db_upgraded
    • pgem_smtp_encryption_type
    • pgem_smtp_password
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • pgem_smtp_port
    • ...

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
  • 8× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Notice
      Undefined variable: title in wp-content/plugins/pocketgecko-email/includes/templates/email-form.php on line 2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pocketgecko-email/includes/scripts.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pocketgecko-email/includes/email.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/pocketgecko-email/includes/templates/email-options.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/pocketgecko-email/includes/templates/email-test.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/pocketgecko-email/includes/templates/email-form.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/pocketgecko-email/includes/shortcode.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pocketgecko-email/pocketgecko-email-admin.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
6 plugin tags: ajax, email, post, smtp, settings...

pocketgecko-email/pocketgecko-email.php 77% from 13 tests

Analyzing the main PHP file in "PocketGecko Email" version 1.0.0
You should first fix the following items:
  • Domain Path: The domain path is invalid: folder "/i18n/languages" does not exist
  • Requires PHP: Required version number should use periods and dots only (ex. "7.0" instead of "")
  • Requires at least: Required version number should use periods and dots only (ex. "7.0" instead of "")

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 plugin568 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP1017164567
JavaScript1001

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions28
▷ Named functions2589.29%
▷ Anonymous functions310.71%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.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
There were not PNG files found in your plugin