10% wp-birthday-users

Code Review | WP Birthday Users

WordPress plugin WP Birthday Users scored10%from 54 tests.

About plugin

  • Plugin page: wp-birthday-users
  • Plugin version: 0.1.8
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jun 12, 2012
  • Latest release: Nov 22, 2012
  • Number of updates: 29
  • Update frequency: every 5.7 days
  • Top authors: omarke85 (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

60+ active /6,227 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
These installer errors require your attention
  • Install procedure had errors
    • > Deprecated in wp-content/plugins/wp-birthday-users/widget.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; BirthdayUsersWidget has a deprecated constructor

Server metrics [RAM: ▼1.74MB] [CPU: ▼57.44ms] Passed 4 tests

A check of server-side resources used by WP Birthday Users
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.25 ▼1.215.78 ▼40.39
Dashboard /wp-admin2.28 ▼1.036.45 ▼46.47
Posts /wp-admin/edit.php2.28 ▼1.087.68 ▼39.23
Add New Post /wp-admin/post-new.php2.28 ▼3.626.90 ▼103.68
Media Library /wp-admin/upload.php2.28 ▼0.967.81 ▼26.17
Users Birthdays /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php2.356.59
Birthdays Options /wp-admin/options-general.php?page=wp-birthday-users/config.php2.288.99

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 37 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
widget_birthdayuserswidget
theysaidso_admin_options

Browser metrics Passed 4 tests

WP Birthday Users: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,914 ▲15313.66 ▼0.699.47 ▲7.6447.10 ▲3.63
Dashboard /wp-admin2,220 ▲405.60 ▼0.0491.16 ▼2.6940.00 ▲1.03
Posts /wp-admin/edit.php2,122 ▲252.11 ▲0.1135.49 ▼0.6332.71 ▼4.36
Add New Post /wp-admin/post-new.php1,547 ▲1923.07 ▲0.05631.69 ▲12.1837.66 ▼11.51
Media Library /wp-admin/upload.php1,428 ▲284.31 ▲0.12107.42 ▲0.8943.31 ▼4.37
Users Birthdays /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php9021.7725.8129.17
Birthdays Options /wp-admin/options-general.php?page=wp-birthday-users/config.php9591.8025.7527.61

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/wp-birthday-users/widget.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; BirthdayUsersWidget has a deprecated constructor
  • The uninstall procedure has failed, leaving 7 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_birthdayuserswidget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wp-birthday-users/config.php
    • > Deprecated in wp-content/plugins/wp-birthday-users/widget.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; BirthdayUsersWidget has a deprecated constructor
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wp-birthday-users/config.php
    • > Deprecated in wp-content/plugins/wp-birthday-users/widget.php+146
    Function create_function() is deprecated
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wp-birthday-users/config.php
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in BirthdayUsersWidget is deprecated since version 4.3.0! Use __construct() instead.
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wp-birthday-users/config.php
    • > Notice in wp-content/plugins/wp-birthday-users/wp-birthday-users.php+30
    Trying to access array offset on value of type bool
  • 8 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wp-birthday-users/config.php
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
    • > GET request to /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php
    • > Notice in wp-content/plugins/wp-birthday-users/wp-birthday-users.php+47
    Undefined index: rebuild
    • > GET request to /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php
    • > Notice in wp-content/plugins/wp-birthday-users/wp-birthday-users.php+48
    Undefined index: come
    • > GET request to /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php
    • > Notice in wp-content/plugins/wp-birthday-users/wp-birthday-users.php+49
    Undefined index: past
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php
    • > Warning in wp-content/plugins/wp-birthday-users/wp-birthday-users.php+104
    count(): Parameter must be an array or an object that implements Countable
    • > GET request to /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php
    • > Notice in wp-content/plugins/wp-birthday-users/wp-birthday-users.php+79
    Undefined index: text
    • > GET request to /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php
    • > Notice in wp-content/plugins/wp-birthday-users/wp-birthday-users.php+97
    Undefined variable: upcoming
    • > GET request to /wp-admin/users.php?page=wp-birthday-users/wp-birthday-users.php
    • > Notice in wp-content/plugins/wp-birthday-users/wp-birthday-users.php+107
    Undefined variable: passed

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-birthday-users/wp-birthday-users.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/wp-birthday-users/widget.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === wp-birthday-users === )
  • Requires at least: Invalid version format
Please take inspiration from this readme.txt

wp-birthday-users/wp-birthday-users.php Passed 13 tests

"WP Birthday Users" version 0.1.8's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
33 characters long description:
Let users fill in there birthday.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected1,372 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP33539593
PO File4175180408
CSS32662371

PHP code Passed 2 tests

A short 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.49
Average class complexity43.00
▷ Minimum class complexity43.00
▷ Maximum class complexity43.00
Average method complexity11.50
▷ Minimum method complexity1.00
▷ Maximum method complexity43.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions18
▷ Named functions18100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
19 compressed PNG files occupy 0.03MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/smoothness/images/ui-icons_454545_256x240.png4.27KB4.11KB▼ 3.78%
images/birthday.png0.64KB0.61KB▼ 4.58%
css/smoothness/images/ui-icons_222222_256x240.png4.27KB4.11KB▼ 3.78%
images/birthday-passed.png0.61KB0.51KB▼ 17.36%
images/present.png0.82KB0.84KB0.00%