94% private-content-login-redirect

Code Review | Private Content Login Redirect

WordPress plugin Private Content Login Redirect scored 94% from 54 tests.

About plugin

  • Plugin page: private-content-l...
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.6.1
  • WordPress version: 5.9.2
  • First release: Jul 11, 2014
  • Latest release: Sep 13, 2016
  • Number of updates: 20
  • Update frequency: every 39.8 days
  • Top authors: meabhisek (100%)

Code review

54 tests

User reviews

12 reviews

Install metrics

1,000+ active / 14,989 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
This plugin's installer ran successfully

Server metrics [RAM: ▼0.02MB] [CPU: ▼301.57ms] Passed 4 tests

Analyzing server-side resources used by Private Content Login Redirect
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0154.09 ▲6.28
Dashboard /wp-admin3.42 ▲0.0133.30 ▼0.54
Posts /wp-admin/edit.php3.65 ▲0.0135.20 ▼0.77
Add New Post /wp-admin/post-new.php6.89 ▼0.0991.74 ▼1,205.58
Media Library /wp-admin/upload.php3.30 ▲0.0025.30 ▲0.62

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Private Content Login Redirect
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,763 ▲916.18 ▲0.526.21 ▼0.512.48 ▲0.04
Dashboard /wp-admin2,895 ▲346.13 ▼0.06116.59 ▼15.47157.50 ▼8.64
Posts /wp-admin/edit.php2,694 ▼03.24 ▲0.0164.30 ▲0.39140.72 ▲1.95
Add New Post /wp-admin/post-new.php1,690 ▲2921.55 ▲5.13459.69 ▲69.26161.57 ▲0.48
Media Library /wp-admin/upload.php1,695 ▼35.54 ▼0.00158.35 ▲17.33188.51 ▲7.08

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
This plugin's uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 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/private-content-login-redirect/private-content-login-redirect.php:27

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
3 plugin tags: redirection, private content, login

private-content-login-redirect/private-content-login-redirect.php 92% from 13 tests

The main file in "Private Content Login Redirect" v. 1.0.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Description: The description should be shorter than 140 characters (currently 240 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
Success! There were no dangerous files found in this plugin13 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP161913

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.33
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%
Functions1
▷ Named functions1100.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
There are no PNG files in this plugin