10% easy-admin-notification

Code Review | Easy Admin Notification

WordPress plugin Easy Admin Notification scored10%from 54 tests.

About plugin

  • Plugin page: easy-admin-notifi...
  • Plugin version: 1.4
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jan 17, 2012
  • Latest release: Feb 12, 2012
  • Number of updates: 43
  • Update frequency: every 0.6 days
  • Top authors: corsonr (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

50+ active /4,996 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Please fix the following installer errors
  • This plugin did not install gracefully
    • > Notice in wp-content/plugins/easy-admin-notification/easy-admin-notification.php+34
    Undefined index: page

Server metrics [RAM: ▼1.92MB] [CPU: ▼62.86ms] Passed 4 tests

An overview of server-side resources used by Easy Admin Notification
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.08 ▼1.385.47 ▼35.43
Dashboard /wp-admin2.10 ▼1.246.48 ▼51.72
Posts /wp-admin/edit.php2.10 ▼1.256.78 ▼68.18
Add New Post /wp-admin/post-new.php2.10 ▼3.786.32 ▼96.10
Media Library /wp-admin/upload.php2.10 ▼1.137.06 ▼25.23
Admin Notification /wp-admin/themes.php?page=ean-settings3.2424.95

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Easy Admin Notification
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.16 ▼1.211.89 ▲0.0641.39 ▼5.21
Dashboard /wp-admin2,210 ▲224.87 ▼0.98109.36 ▲6.9039.89 ▼2.74
Posts /wp-admin/edit.php2,093 ▼02.00 ▼0.0340.81 ▼0.2234.83 ▼4.34
Add New Post /wp-admin/post-new.php1,545 ▲2623.15 ▲0.01640.11 ▼12.4161.40 ▼0.60
Media Library /wp-admin/upload.php1,392 ▲74.27 ▲0.0995.64 ▼2.3442.05 ▼0.52
Admin Notification /wp-admin/themes.php?page=ean-settings9512.1428.6530.69

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
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/easy-admin-notification/easy-admin-notification.php+34
    Undefined index: page
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
    • > GET request to /wp-admin/themes.php?page=ean-settings
    • > User deprecated in wp-includes/functions.php+5453
    Function get_currentuserinfo is deprecated since version 4.5.0! Use wp_get_current_user() instead.
  • 7 occurences, only the last one shown
    • > GET request to /wp-admin/themes.php?page=ean-settings
    • > Notice in wp-content/plugins/easy-admin-notification/includes/functions/ean_functions.php+113
    Trying to access array offset on value of type bool

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 items
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function load_plugin_textdomain() in wp-content/plugins/easy-admin-notification/easy-admin-notification.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/easy-admin-notification/includes/functions/ean_functions.php:43
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/easy-admin-notification/includes/options.php:15

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need your attention:
  • Screenshots: These screenshots do not have images: #1 (The Easy Admin Notification in English), #2 (The Easy Admin Notification in French)
  • Tags: Please reduce the number of tags, currently 11 tag instead of maximum 10
You can take inspiration from this readme.txt

easy-admin-notification/easy-admin-notification.php 92% from 13 tests

This is the main PHP file of "Easy Admin Notification" version 1.4, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 143 characters long)

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
No dangerous file extensions were detected1,041 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP5138119432
CSS234150408
PO File26264151
JavaScript29250

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.50
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%
Functions15
▷ Named functions15100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
15 compressed PNG files occupy 0.15MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/css/images/ui-icons_454545_256x240.png4.27KB4.11KB▼ 3.78%
includes/css/images/ui-bg_flat_0_aaaaaa_40x100.png0.18KB0.08KB▼ 51.67%
includes/css/images/ui-icons_cd0a0a_256x240.png4.27KB4.11KB▼ 3.78%
includes/css/images/ui-bg_glass_65_ffffff_1x400.png0.10KB0.10KB▼ 5.71%
includes/css/images/ui-bg_inset-soft_95_fef1ec_1x100.png0.12KB0.16KB0.00%