84% bdvs-password-reset

Code Review | Password Reset with Code for WordPress REST API

WordPress plugin Password Reset with Code for WordPress REST API scored84%from 54 tests.

About plugin

  • Plugin page: bdvs-password-reset
  • Plugin version: 0.0.16
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.3
  • WordPress version: 6.3.1
  • First release: May 9, 2020
  • Latest release: Aug 23, 2023
  • Number of updates: 28
  • Update frequency: every 42.9 days
  • Top authors: dominic_ks (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

1,000+ active /7,970 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.06MB] [CPU: ▼5.07ms] Passed 4 tests

Analyzing server-side resources used by Password Reset with Code for WordPress REST API
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0643.65 ▲4.00
Dashboard /wp-admin3.37 ▲0.0345.31 ▼12.41
Posts /wp-admin/edit.php3.48 ▲0.1346.80 ▲2.00
Add New Post /wp-admin/post-new.php5.96 ▲0.0789.35 ▼7.47
Media Library /wp-admin/upload.php3.29 ▲0.0634.91 ▼2.39

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
db_upgraded
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Password Reset with Code for WordPress REST API
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.29 ▼1.091.63 ▼0.1141.84 ▲3.36
Dashboard /wp-admin2,206 ▲144.85 ▼0.03108.76 ▲4.2439.67 ▼7.12
Posts /wp-admin/edit.php2,089 ▼02.03 ▼0.0141.16 ▲5.4135.53 ▲4.09
Add New Post /wp-admin/post-new.php1,542 ▲2818.29 ▲0.73613.94 ▼36.6355.94 ▲8.57
Media Library /wp-admin/upload.php1,388 ▼04.23 ▲0.0394.78 ▼6.1944.77 ▲1.06

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments

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
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
Please fix the following items
  • 8× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bdvs-password-reset/inc/api/api.route.reset-password.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bdvs-password-reset/inc/api/api.route.reset-password.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bdvs-password-reset/inc/api/api.route.reset-password.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'WP_User' not found in wp-content/plugins/bdvs-password-reset/inc/class/class.user.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bdvs-password-reset/inc/api/api.route.validate-code.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bdvs-password-reset/inc/api/api.route.set-password.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bdvs-password-reset/inc/api/api.route.reset-password.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'WP_User' not found in wp-content/plugins/bdvs-password-reset/inc/class/class.user.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/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 is important because it is parsed by WordPress.org for the public listing of your plugin
2 plugin tags: wp-api, password reset

bdvs-password-reset/bdvs-password-reset.php 92% from 13 tests

The main file in "Password Reset with Code for WordPress REST API" v. 0.0.16 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:
  • Domain Path: The domain path folder was not found ("/languages")

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
There were no executable files found in this plugin309 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP9158225309

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity16.00
▷ Minimum class complexity16.00
▷ Maximum class complexity16.00
Average method complexity2.88
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods450.00%
▷ Protected methods00.00%
▷ Private methods450.00%
Functions17
▷ Named functions847.06%
▷ Anonymous functions952.94%
Constants0
▷ Global constants00.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
No PNG files were detected