78% passclip-auth-for-wordpress

Code Review | PassClip Auth for WordPress

WordPress plugin PassClip Auth for WordPress scored78%from 54 tests.

About plugin

  • Plugin page: passclip-auth-for...
  • Plugin version: 1.0.5
  • PHP compatiblity: 5.3.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.3.2
  • WordPress version: 6.3.1
  • First release: Aug 16, 2017
  • Latest release: Dec 27, 2019
  • Number of updates: 15
  • Update frequency: every 57.4 days
  • Top authors: Passlogy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,035 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.29MB] [CPU: ▼3.30ms] Passed 4 tests

An overview of server-side resources used by PassClip Auth for WordPress
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.75 ▲0.2935.95 ▼7.19
Dashboard /wp-admin3.59 ▲0.2947.51 ▼1.65
Posts /wp-admin/edit.php3.71 ▲0.3549.09 ▲4.50
Add New Post /wp-admin/post-new.php6.17 ▲0.2985.74 ▼8.87
Media Library /wp-admin/upload.php3.52 ▲0.2936.87 ▲5.58

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 23 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
passclip_auth_options

Browser metrics Passed 4 tests

PassClip Auth for WordPress: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,835 ▲10013.21 ▼1.161.65 ▼0.1541.72 ▼5.48
Dashboard /wp-admin2,241 ▲565.84 ▲0.91100.15 ▼17.1644.01 ▲1.78
Posts /wp-admin/edit.php2,123 ▲342.02 ▲0.0135.10 ▼1.5834.99 ▲2.15
Add New Post /wp-admin/post-new.php1,566 ▲4623.30 ▲0.12707.40 ▲20.0746.51 ▼9.36
Media Library /wp-admin/upload.php1,423 ▲354.23 ▲0.0296.84 ▲0.5840.12 ▼1.80
PCA Mail Settings /wp-admin/passclip-auth.php?page=pca_mail_setting_page260.440.1514.55
Manage PCA Users /wp-admin/passclip-auth.php?page=pca_manage_users260.440.075.86
PassClip Auth Options /wp-admin/passclip-auth.php?page=pca_options_page260.440.115.46
PassClip Auth /wp-admin/passclip-auth.php260.440.086.31

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 50% 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 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 4× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATH/wp-admin/includes/class-wp-users-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/passclip-auth-for-wordpress/class-pca-users-list-table.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/passclip-auth-for-wordpress/class-passclip-auth-login-widget.php:5
    • > PHP Warning
      require_once(ABSPATH/wp-admin/includes/class-wp-users-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/passclip-auth-for-wordpress/class-pca-users-list-table.php on line 3
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/passclip-auth-for-wordpress/class-pca-users-list-table.php on line 3

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There are user-side issues you should fix
    • > GET request to /wp-admin/passclip-auth.php?page=pca_mail_setting_page
    • > Network (severe)
    wp-admin/passclip-auth.php?page=pca_mail_setting_page - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/passclip-auth.php?page=pca_manage_users
    • > Network (severe)
    wp-admin/passclip-auth.php?page=pca_manage_users - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/passclip-auth.php?page=pca_options_page
    • > Network (severe)
    wp-admin/passclip-auth.php?page=pca_options_page - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/passclip-auth.php
    • > Network (severe)
    wp-admin/passclip-auth.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need to be fixed:
  • Donate link: Please fix this invalid url: ""
The official readme.txt might help

passclip-auth-for-wordpress/passclip-auth.php 92% from 13 tests

"PassClip Auth for WordPress" version 1.0.5's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("passclip-auth-for-wordpress.php" instead of "passclip-auth.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin2,141 lines of code in 18 files:
LanguageFilesBlank linesComment linesLines of code
PHP93495001,607
PO File2184212388
JavaScript4190118
CSS37028

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity12.67
▷ Minimum class complexity1.00
▷ Maximum class complexity19.00
Average method complexity2.94
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods18
▷ Static methods211.11%
▷ Public methods1266.67%
▷ Protected methods527.78%
▷ Private methods15.56%
Functions61
▷ Named functions6098.36%
▷ Anonymous functions11.64%
Constants31
▷ Global constants31100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
PNG images were not found in this plugin