84% wp-custom-access-lite

Code Review | WP - Custom Access Lite

WordPress plugin WP - Custom Access Lite scored84%from 54 tests.

About plugin

  • Plugin page: wp-custom-access-...
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.9.6
  • WordPress version: 6.3.1
  • First release: Jul 12, 2018
  • Latest release: Jul 12, 2018
  • Number of updates: 4
  • Update frequency: N/A
  • Top authors: Van Stein en Groentjes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /574 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

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

Analyzing server-side resources used by WP - Custom Access Lite
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.65 ▼0.8112.07 ▼30.68
Dashboard /wp-admin3.59 ▲0.2953.07 ▼0.47
Posts /wp-admin/edit.php3.70 ▲0.3551.28 ▲1.62
Add New Post /wp-admin/post-new.php6.17 ▲0.28102.80 ▲0.83
Media Library /wp-admin/upload.php3.51 ▲0.2943.96 ▲8.07
Custom Access /wp-admin/admin.php?page=custom_access_lite3.7637.06
Add users /wp-admin/admin.php?page=ca-lite-add_users3.7637.20
Set pages /wp-admin/admin.php?page=ca-lite-set_pages3.7635.15
view logs /wp-admin/admin.php?page=ca-lite-log3.7636.94
options /wp-admin/admin.php?page=ca-lite-options3.7633.97

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 31 new files
Database: 3 new tables, 7 new options
New tables
wp_custom_access_lite_session
wp_custom_access_lite_accounts
wp_custom_access_lite_logger
New WordPress options
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
CUSTOM_ACCESS_LITE_Logger_pages
widget_recent-comments
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

WP - Custom Access Lite: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,831 ▲4514.37 ▼0.311.79 ▼0.3742.02 ▼3.04
Dashboard /wp-admin2,237 ▲575.78 ▲0.13100.14 ▲1.9144.76 ▼1.08
Posts /wp-admin/edit.php2,135 ▲382.05 ▲0.0534.76 ▼1.9449.01 ▲13.81
Add New Post /wp-admin/post-new.php1,573 ▲2823.10 ▼0.14688.59 ▲33.7352.65 ▼12.21
Media Library /wp-admin/upload.php1,442 ▲514.44 ▲0.19113.30 ▲12.2652.59 ▲4.70
Custom Access /wp-admin/admin.php?page=custom_access_lite1,0862.2829.1137.69
Add users /wp-admin/admin.php?page=ca-lite-add_users1,5012.3840.2135.83
Set pages /wp-admin/admin.php?page=ca-lite-set_pages9902.2826.2635.83
view logs /wp-admin/admin.php?page=ca-lite-log1,1752.3541.0436.21
options /wp-admin/admin.php?page=ca-lite-options1,1092.0229.2433.75

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

SRP 50% 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
The following issues need your attention
  • 11× PHP files output non-empty strings when accessed directly via GET requests (only 10 are shown):
    • > /wp-content/plugins/wp-custom-access-lite/classes/seng_login_screen.php
    • > /wp-content/plugins/wp-custom-access-lite/classes/seng_gebruiker.php
    • > /wp-content/plugins/wp-custom-access-lite/functions/semi_functions.php
    • > /wp-content/plugins/wp-custom-access-lite/functions/prime_functions.php
    • > /wp-content/plugins/wp-custom-access-lite/wp-custom-access-lite.php
    • > /wp-content/plugins/wp-custom-access-lite/classes/errormessage.php
    • > /wp-content/plugins/wp-custom-access-lite/classes/useraccount.php
    • > /wp-content/plugins/wp-custom-access-lite/classes/seng_uninstall.php
    • > /wp-content/plugins/wp-custom-access-lite/classes/installation.php
    • > /wp-content/plugins/wp-custom-access-lite/classes/admin_menu_logger.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
6 plugin tags: lite, login, access, management, access management...

wp-custom-access-lite/wp-custom-access-lite.php 85% from 13 tests

This is the main PHP file of "WP - Custom Access Lite" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Domain Path: The domain path is invalid: folder "/languages" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin11,762 lines of code in 23 files:
LanguageFilesBlank linesComment linesLines of code
CSS420146,922
PHP111683472,428
JavaScript76232502,124
SVG100288

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity21.90
▷ Minimum class complexity1.00
▷ Maximum class complexity109.00
Average method complexity3.68
▷ Minimum method complexity1.00
▷ Maximum method complexity24.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes10
▷ Abstract classes00.00%
▷ Concrete classes10100.00%
▷ Final classes00.00%
Methods78
▷ Static methods00.00%
▷ Public methods6684.62%
▷ Protected methods00.00%
▷ Private methods1215.38%
Functions36
▷ Named functions36100.00%
▷ Anonymous functions00.00%
Constants16
▷ Global constants16100.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.05MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
logo.png46.34KB11.77KB▼ 74.60%