94% admin-private-note-on-users

Code Review | Admin Private Note on users

WordPress plugin Admin Private Note on users scored 94% from 54 tests.

About plugin

  • Plugin page: admin-private-not...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.7.3
  • WordPress version: 5.9.2
  • First release: Jun 20, 2015
  • Latest release: Apr 12, 2017
  • Number of updates: 19
  • Update frequency: every 35.2 days
  • Top authors: wplizer (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

30+ active / 1,445 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

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

An overview of server-side resources used by Admin Private Note on users
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0254.55 ▲6.18
Dashboard /wp-admin3.43 ▲0.0333.70 ▲0.99
Posts /wp-admin/edit.php3.66 ▲0.0237.47 ▲0.54
Add New Post /wp-admin/post-new.php6.90 ▼0.0794.36 ▼1,166.82
Media Library /wp-admin/upload.php3.31 ▲0.0223.31 ▼2.24

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 8 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Admin Private Note on users
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,767 ▲1316.01 ▲0.445.63 ▼0.542.44 ▼0.36
Dashboard /wp-admin2,896 ▲356.22 ▼0.03115.28 ▼18.85155.32 ▼7.31
Posts /wp-admin/edit.php2,694 ▼03.24 ▲0.0064.29 ▼0.68138.71 ▼4.24
Add New Post /wp-admin/post-new.php1,643 ▼13815.64 ▼1.51399.99 ▼29.22144.94 ▼10.49
Media Library /wp-admin/upload.php1,705 ▲45.54 ▲0.03138.50 ▲0.82187.21 ▼1.41

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

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
The following issues need your attention
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/admin-private-note-on-users/admin_private_note.php:14

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 93% from 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: description, hidden, admin, users list, note...

admin-private-note-on-users/admin_private_note.php 85% from 13 tests

The main file in "Admin Private Note on users" v. 1.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("admin-private-note-on-users.php" instead of "admin_private_note.php")

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 detected73 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP1161167
JavaScript20106

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.26
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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.04MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png38.62KB12.73KB▼ 67.03%