72% eonet-manual-user-approve

Code Review | Eonet Manual User Approve

WordPress plugin Eonet Manual User Approve scored72%from 54 tests.

About plugin

  • Plugin page: eonet-manual-user...
  • Plugin version: 2.1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.0.3
  • WordPress version: 6.3.1
  • First release: Oct 21, 2016
  • Latest release: Feb 2, 2019
  • Number of updates: 40
  • Update frequency: every 20.9 days
  • Top authors: alkaweb (80%)antonioeatgoat (22.5%)

Code review

54 tests

User reviews

12 reviews

Install metrics

1,000+ active /22,855 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.16MB] [CPU: ▼0.86ms] Passed 4 tests

Analyzing server-side resources used by Eonet Manual User Approve
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.62 ▲0.1641.12 ▲1.20
Dashboard /wp-admin3.48 ▲0.1749.44 ▲0.33
Posts /wp-admin/edit.php3.53 ▲0.1752.51 ▲0.85
Add New Post /wp-admin/post-new.php6.01 ▲0.1395.79 ▼5.82
Media Library /wp-admin/upload.php3.40 ▲0.1737.84 ▲1.60
Manual User Approve /wp-admin/admin.php?page=?page=eonet&eo_settings=manual-user-approve3.1724.01
Eonet /wp-admin/admin.php?page=eonet3.4036.88

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 96 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
db_upgraded
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Eonet Manual User Approve
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,963 ▲21714.25 ▼0.129.68 ▲7.9232.88 ▼10.09
Dashboard /wp-admin2,250 ▲595.41 ▲0.37105.45 ▲1.2295.74 ▲56.48
Posts /wp-admin/edit.php2,139 ▲502.51 ▲0.5242.50 ▲5.8447.77 ▲13.35
Add New Post /wp-admin/post-new.php1,552 ▲3317.86 ▼5.51696.86 ▲28.8841.93 ▼17.26
Media Library /wp-admin/upload.php1,426 ▲444.63 ▲0.42107.21 ▲5.4790.83 ▲47.23
Manual User Approve /wp-admin/admin.php?page=?page=eonet&eo_settings=manual-user-approve280.440.083.64
Eonet /wp-admin/admin.php?page=eonet1,2142.2334.1377.13

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 19× PHP files output text when accessed directly (only 10 are shown):
    • > /wp-content/plugins/eonet-manual-user-approve/core/EonetMetaboxes.php
    • > /wp-content/plugins/eonet-manual-user-approve/core/admin/pages/EonetPageExtensions.php
    • > /wp-content/plugins/eonet-manual-user-approve/core/admin/pages/EonetPageSettings.php
    • > /wp-content/plugins/eonet-manual-user-approve/core/EonetGoogleFontLoader.php
    • > /wp-content/plugins/eonet-manual-user-approve/core/admin/pages/EonetPageSupport.php
    • > /wp-content/plugins/eonet-manual-user-approve/component-manual-user-approve/classes/Eonet_MUA_Sender.php
    • > /wp-content/plugins/eonet-manual-user-approve/core/Eonet.php
    • > /wp-content/plugins/eonet-manual-user-approve/core/bootstrap.php
    • > /wp-content/plugins/eonet-manual-user-approve/core/admin/pages/EonetPageThemes.php
    • > /wp-content/plugins/eonet-manual-user-approve/core/EonetOptions.php
  • 7× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/eonet-manual-user-approve/core/admin/pages/views/support.php:1
    • > PHP Fatal error
      Uncaught Error: Class 'Eonet\\Core\\Admin\\EonetAdmin' not found in wp-content/plugins/eonet-manual-user-approve/core/admin/pages/views/themes.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'Eonet\\Core\\EonetComponents' not found in wp-content/plugins/eonet-manual-user-approve/core/admin/pages/views/extensions.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'Eonet\\Core\\EonetComponents' not found in wp-content/plugins/eonet-manual-user-approve/core/admin/pages/views/settings.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/eonet-manual-user-approve/component-manual-user-approve/settings.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'Eonet\\Core\\EonetComponents' not found in wp-content/plugins/eonet-manual-user-approve/core/admin/views/wrapper.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function do_action() in wp-content/plugins/eonet-manual-user-approve/component-manual-user-approve/templates/members/activate.php:20

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)
There are user-side issues you should fix
    • > GET request to /wp-admin/admin.php?page=?page=eonet&eo_settings=manual-user-approve
    • > Network (severe)
    wp-admin/admin.php?page=?page=eonet&eo_settings=manual-user-approve - Failed to load resource: the server responded with a status of 403 (Forbidden)

Optimizations

Plugin configuration 96% 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
7 plugin tags: login, sign up, registration, users, user management...

eonet-manual-user-approve/init.php 92% from 13 tests

The main PHP file in "Eonet Manual User Approve" ver. 2.1.3 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("eonet-manual-user-approve.php" instead of "init.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
Everything looks great! No dangerous files found in this plugin24,019 lines of code in 56 files:
LanguageFilesBlank linesComment linesLines of code
PHP291,0751,36112,047
SVG5039,167
Sass144271,771
JavaScript5171161552
PO File1192232480
CSS20632

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity22.35
▷ Minimum class complexity1.00
▷ Maximum class complexity128.00
Average method complexity3.25
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces6
Interfaces0
Traits0
Classes17
▷ Abstract classes15.88%
▷ Concrete classes1694.12%
▷ Final classes00.00%
Methods165
▷ Static methods5835.15%
▷ Public methods12877.58%
▷ Protected methods3521.21%
▷ Private methods21.21%
Functions14
▷ Named functions14100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants350.00%
▷ Class constants350.00%
▷ Public constants3100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
12 PNG files occupy 0.53MB with 0.18MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
core/assets/images/logo_colored.png10.13KB6.09KB▼ 39.85%
core/assets/images/menu_icon.png1.94KB1.28KB▼ 34.04%
core/assets/images/logo.png10.69KB6.80KB▼ 36.38%
core/assets/images/themes/woffice.png446.42KB194.26KB▼ 56.48%
core/assets/images/colorpicker/hue.png0.49KB0.50KB0.00%