72% dynamic-password

Code Review | Dynamic Password

WordPress plugin Dynamic Password scored72%from 54 tests.

About plugin

  • Plugin page: dynamic-password
  • Plugin version: 1.0
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-4.8.2
  • WordPress version: 6.3.1
  • First release: Sep 26, 2017
  • Latest release: Sep 26, 2017
  • Number of updates: 3
  • Update frequency: every 1.0 days
  • Top authors: nyasro (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /635 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
The plugin installed successfully, without throwing any errors or notices

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

This is a short check of server-side resources used by Dynamic Password
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0337.14 ▼3.43
Dashboard /wp-admin3.33 ▼0.0245.90 ▼14.62
Posts /wp-admin/edit.php3.38 ▲0.0242.58 ▼4.35
Add New Post /wp-admin/post-new.php5.91 ▲0.0277.48 ▼15.48
Media Library /wp-admin/upload.php3.25 ▲0.0234.57 ▲0.44
Dynamic Password /wp-admin/options-general.php?page=dynamic-password3.2430.04

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Dynamic Password
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,826 ▲5513.66 ▼0.971.73 ▼0.6344.20 ▲0.61
Dashboard /wp-admin2,225 ▲404.83 ▼1.07109.52 ▼8.3043.37 ▼2.94
Posts /wp-admin/edit.php2,108 ▲192.04 ▼0.0236.12 ▲1.5539.10 ▲2.71
Add New Post /wp-admin/post-new.php1,528 ▲1123.41 ▲5.61648.97 ▼2.3658.45 ▲5.73
Media Library /wp-admin/upload.php1,407 ▲254.25 ▲0.0696.97 ▲0.1245.03 ▲0.41
Dynamic Password /wp-admin/options-general.php?page=dynamic-password8072.0325.8624.69

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP 0% 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 fix the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/dynamic-password/dynamic-password.php
  • 3× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function DY_PWD\\dyPwd__() in wp-content/plugins/dynamic-password/inc/utils.php:21
    • > PHP Fatal error
      Uncaught Error: Call to undefined function DY_PWD\\add_action() in wp-content/plugins/dynamic-password/inc/backend.php:24
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/dynamic-password/inc/authenticate.php:8

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please take a look at the following user-side issues
    • > GET request to /wp-admin/options-general.php?page=dynamic-password
    • > Network (severe)
    http://localhost:35729/livereload.js - Failed to load resource: net::ERR_CONNECTION_REFUSED

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
4 plugin tags: password, protection, security, dynamic

dynamic-password/dynamic-password.php 92% from 13 tests

"Dynamic Password" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Text Domain: The text domain name should consist of only dashes and lowercase characters

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected408 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP412292305
Sass121078
CSS18025

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity10.50
▷ Minimum class complexity1.00
▷ Maximum class complexity20.00
Average method complexity2.36
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods14
▷ Static methods321.43%
▷ Public methods1392.86%
▷ Protected methods00.00%
▷ Private methods17.14%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected