83% almost-users-only

Code Review | Almost Users Only

WordPress plugin Almost Users Only scored83%from 54 tests.

About plugin

  • Plugin page: almost-users-only
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.4.2
  • WordPress version: 6.3.1
  • First release: Nov 27, 2012
  • Latest release: Nov 29, 2012
  • Number of updates: 6
  • Update frequency: every 0.3 days
  • Top authors: madsphi (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

10+ active /1,443 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼5.18ms] Passed 4 tests

This is a short check of server-side resources used by Almost Users Only
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.77 ▼5.14
Dashboard /wp-admin3.32 ▲0.0145.19 ▼5.45
Posts /wp-admin/edit.php3.37 ▲0.0146.28 ▼3.76
Add New Post /wp-admin/post-new.php5.90 ▲0.0189.03 ▼6.38
Media Library /wp-admin/upload.php3.24 ▲0.0136.18 ▲4.11
Almost Users Only /wp-admin/options-general.php?page=mp_auo_users_only3.2130.79

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Almost Users Only
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.39 ▼1.251.75 ▲0.1139.81 ▼3.34
Dashboard /wp-admin2,210 ▲224.85 ▼0.03108.90 ▲7.1643.70 ▲0.27
Posts /wp-admin/edit.php2,096 ▲42.05 ▼0.0041.43 ▲1.2637.53 ▲2.63
Add New Post /wp-admin/post-new.php1,536 ▲322.97 ▼0.33620.43 ▼48.0060.24 ▲2.45
Media Library /wp-admin/upload.php1,392 ▲14.30 ▼0.0093.31 ▼6.5240.26 ▼6.48
Almost Users Only /wp-admin/options-general.php?page=mp_auo_users_only7762.0326.3325.01

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

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
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/almost-users-only/users-only.php:13

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
  • Screenshots: Screenshot #1 (Plugin administration) image missing
The official readme.txt might help

almost-users-only/users-only.php 85% from 13 tests

The main PHP file in "Almost Users Only" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 237 characters long)
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("almost-users-only.php" instead of "users-only.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
There were no executable files found in this plugin55 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2201755

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions5
▷ Named functions5100.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.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png7.31KB4.05KB▼ 44.59%