63% birthday-emails

Code Review | Birthday Emails

WordPress plugin Birthday Emails scored 63% from 54 tests.

About plugin

  • Plugin page: birthday-emails
  • Plugin version: 1.2.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.3
  • WordPress version: 6.3.1
  • First release: Jul 3, 2017
  • Latest release: Dec 9, 2019
  • Number of updates: 23
  • Update frequency: every 38.7 days
  • Top authors: carman23 (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

600+ active / 8,692 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

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

A check of server-side resources used by Birthday Emails
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0636.92 ▼3.36
Dashboard /wp-admin3.35 ▲0.0546.37 ▼5.11
Posts /wp-admin/edit.php3.40 ▲0.0448.61 ▲2.41
Add New Post /wp-admin/post-new.php5.93 ▲0.0482.32 ▼14.15
Media Library /wp-admin/upload.php3.27 ▲0.0435.19 ▲1.87

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: 1 new table, 9 new options
New tables
wp_cjl_bdemail_unsubscribe
New WordPress options
widget_recent-posts
widget_recent-comments
cjlbdemailCountDown
cjl_bdemail_settings
cjlbdemailID
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Birthday Emails
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.21 ▼1.101.60 ▼0.2340.28 ▼2.70
Dashboard /wp-admin2,210 ▲224.84 ▼1.06110.39 ▼6.2942.09 ▼2.69
Posts /wp-admin/edit.php2,090 ▲42.01 ▼0.0440.03 ▲5.1635.77 ▲3.82
Add New Post /wp-admin/post-new.php1,517 ▼217.76 ▼5.45679.09 ▼5.5250.58 ▼22.40
Media Library /wp-admin/upload.php1,392 ▲44.19 ▼0.0192.59 ▼15.8742.60 ▼6.84
Birthday Emails Settings /wp-admin/birthday-emails.php260.440.0812.64

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • The uninstall procedure failed, leaving 1 table in the database
    • wp_cjl_bdemail_unsubscribe
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

SRP 0% 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
Almost there! Just fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/birthday-emails/unsubscribe.php
  • 4× PHP files trigger server errors when accessed directly:
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/birthday-emails/birthday-emails.php on line 36
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/birthday-emails/birthday-emails.php:90
    • > PHP Warning
      include_once(ABSPATHwp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/birthday-emails/birthday-emails.php on line 36
    • > PHP Warning
      include_once(): Failed opening 'ABSPATHwp-admin/includes/plugin.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/birthday-emails/birthday-emails.php on line 36

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please fix the following user-side errors
    • > GET request to /wp-admin/birthday-emails.php
    • > Network (severe)
    wp-admin/birthday-emails.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
8 plugin tags: membership, profile fields, member, buddypress, wordpress...

birthday-emails/birthday-emails.php Passed 13 tests

"Birthday Emails" version 1.2.3's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
79 characters long description:
Automatically send an email to WordPress or BuddyPress users on their birthday.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin1,042 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2561911,042

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.53
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%
Functions39
▷ Named functions39100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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
There were not PNG files found in your plugin