74% web3-wallet-login

Code Review | Web3 Wallet Login

WordPress plugin Web3 Wallet Login scored74%from 54 tests.

About plugin

  • Plugin page: web3-wallet-login
  • Plugin version: 1.1.1
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.9
  • WordPress version: 6.3.1
  • First release: Apr 12, 2022
  • Latest release: Apr 13, 2022
  • Number of updates: 7
  • Update frequency: every 0.1 days
  • Top authors: vpallegar (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /703 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.09MB] [CPU: ▼1.92ms] Passed 4 tests

A check of server-side resources used by Web3 Wallet Login
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1041.11 ▼1.84
Dashboard /wp-admin3.40 ▲0.1046.42 ▲1.87
Posts /wp-admin/edit.php3.51 ▲0.1647.38 ▼0.46
Add New Post /wp-admin/post-new.php5.98 ▲0.0994.39 ▼5.75
Media Library /wp-admin/upload.php3.32 ▲0.0938.23 ▲0.37
Web3 Wallet Login /wp-admin/options-general.php?page=web3-wallet-login3.2933.04

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 102 new files
Database: 1 new table, 7 new options
New tables
wp_web3login_log
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
db_upgraded
widget_recent-posts
widget_theysaidso_widget
web3login_db_version

Browser metrics Passed 4 tests

A check of browser resources used by Web3 Wallet Login
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲4713.29 ▼1.014.42 ▲1.6440.52 ▼11.01
Dashboard /wp-admin2,213 ▲224.85 ▼1.03109.13 ▲7.5042.09 ▼1.93
Posts /wp-admin/edit.php2,093 ▲42.01 ▲0.0240.08 ▲2.7935.69 ▲0.88
Add New Post /wp-admin/post-new.php1,517 ▼1617.73 ▼5.34648.86 ▲4.5253.63 ▲2.69
Media Library /wp-admin/upload.php1,392 ▲44.19 ▼0.04101.52 ▼8.8443.89 ▼1.38
Web3 Wallet Login /wp-admin/options-general.php?page=web3-wallet-login7852.0325.9930.48

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • Zombie tables detected upon uninstall: 1 table
    • wp_web3login_log
  • This plugin does not fully uninstall, leaving 7 options in the database
    • can_compress_scripts
    • db_upgraded
    • web3login_db_version
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 32× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      require_once(): Failed opening required 'wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/../vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/HmacDRBGTest.php on line 2
    • > PHP Fatal error
      require_once(): Failed opening required 'wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/../vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/ApiTest.php on line 2
    • > PHP Fatal error
      require_once(): Failed opening required 'wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/../vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/ED25519Test.php on line 2
    • > PHP Warning
      require(wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/benchmarks/../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/benchmarks/EllipticBench.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'Elliptic\\Curve\\BaseCurve' not found in wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/lib/Curve/ShortCurve.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'BI\\BigInteger' not found in wp-content/plugins/web3-wallet-login/vendor/simplito/bigint-wrapper-php/test/test.php:24
    • > PHP Warning
      require_once(wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/CurveTest.php on line 2
    • > PHP Fatal error
      Uncaught Exception: Extension bcmath not loaded in wp-content/plugins/web3-wallet-login/vendor/simplito/bigint-wrapper-php/lib/BigInteger.php:236
    • > PHP Warning
      require_once(wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/ECDHTest.php on line 2
    • > PHP Warning
      require_once(wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/web3-wallet-login/vendor/simplito/elliptic-php/tests/HmacDRBGTest.php on line 2

User-side errors Passed 1 test

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

Optimizations

Plugin configuration Passed 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
6 plugin tags: polygon, login, wordpress, ethereum, wallet...

web3-wallet-login/web3-wallet-login.php Passed 13 tests

"Web3 Wallet Login" version 1.1.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
51 characters long description:
Allow users to login via their web3 wallet address.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected12,880 lines of code in 83 files:
LanguageFilesBlank linesComment linesLines of code
PHP571,5621,02010,854
JSON900792
JavaScript312657614
Markdown71790469
YAML313061
XML24050
CSS11030
make13010

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity25.31
▷ Minimum class complexity1.00
▷ Maximum class complexity166.00
Average method complexity2.56
▷ Minimum method complexity1.00
▷ Maximum method complexity26.00
Code structure
Namespaces14
Interfaces0
Traits0
Classes39
▷ Abstract classes25.13%
▷ Concrete classes3794.87%
▷ Final classes25.41%
Methods582
▷ Static methods11820.27%
▷ Public methods54092.78%
▷ Protected methods71.20%
▷ Private methods356.01%
Functions107
▷ Named functions9084.11%
▷ Anonymous functions1715.89%
Constants25
▷ Global constants1560.00%
▷ Class constants1040.00%
▷ Public constants440.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin