73% custom-registration-and-login

Code Review | Custom Registration and Login

WordPress plugin Custom Registration and Login scored73%from 54 tests.

About plugin

  • Plugin page: custom-registrati...
  • Plugin version: 1.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.7
  • WordPress version: 6.3.1
  • First release: Apr 25, 2019
  • Latest release: Apr 25, 2019
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: nidhi1512 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /9,848 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼1.86MB] [CPU: ▼58.49ms] Passed 4 tests

An overview of server-side resources used by Custom Registration and Login
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.14 ▼1.325.75 ▼35.41
Dashboard /wp-admin2.16 ▼1.186.34 ▼52.94
Posts /wp-admin/edit.php2.16 ▼1.207.13 ▼46.08
Add New Post /wp-admin/post-new.php2.16 ▼3.735.83 ▼99.51
Media Library /wp-admin/upload.php2.16 ▼1.075.95 ▼30.86

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Custom Registration and Login
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,795 ▲914.67 ▼0.101.52 ▼0.3438.10 ▼5.50
Dashboard /wp-admin2,197 ▲305.58 ▼0.0486.98 ▼10.3736.70 ▼0.07
Posts /wp-admin/edit.php2,102 ▲22.03 ▲0.0235.42 ▼2.0231.47 ▼9.61
Add New Post /wp-admin/post-new.php1,528 ▲223.13 ▲0.02612.42 ▼21.7663.57 ▼28.36
Media Library /wp-admin/upload.php1,399 ▼44.21 ▲0.09100.91 ▼6.9544.49 ▲2.03

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • Uninstall procedure had uncaught errors
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the custom_css handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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
Please take a closer look at the following
  • 4× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/custom-registration-and-login/custom_edit_profile.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_script() in wp-content/plugins/custom-registration-and-login/change_pass.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_register_style() in wp-content/plugins/custom-registration-and-login/registration_and_Login.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_get_current_user() in wp-content/plugins/custom-registration-and-login/custom_profile.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 90% 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
Please fix the following attributes:
  • Contributors: The plugin contributors field is missing
You can take inspiration from this readme.txt

custom-registration-and-login/registration_and_Login.php 85% from 13 tests

"Custom Registration and Login" version 1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 302 characters long)
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("custom-registration-and-login.php" instead of "registration_and_Login.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected594 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP4447100563
CSS12031

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.30
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%
Functions21
▷ Named functions21100.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
3 PNG files occupy 0.27MB with 0.19MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assests/Screenshot-1.png89.11KB26.78KB▼ 69.95%
assests/Screenshot-3.png92.39KB27.50KB▼ 70.24%
assests/Screenshot-2.png92.50KB27.70KB▼ 70.05%