74% pl8app-custom-bep20-token-widget

Code Review | pl8app custom bep20 token widget

WordPress plugin pl8app custom bep20 token widget scored74%from 54 tests.

About plugin

  • Plugin page: pl8app-custom-bep...
  • Plugin version: 1.2
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.2
  • WordPress version: 6.3.1
  • First release: Sep 16, 2021
  • Latest release: Jul 27, 2023
  • Number of updates: 24
  • Update frequency: every 28.3 days
  • Top authors: pl8apptoken (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,156 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.19MB] [CPU: ▼3.18ms] Passed 4 tests

Analyzing server-side resources used by pl8app custom bep20 token widget
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.65 ▲0.1845.31 ▲1.81
Dashboard /wp-admin3.49 ▲0.1851.39 ▲5.39
Posts /wp-admin/edit.php3.60 ▲0.2452.41 ▲1.33
Add New Post /wp-admin/post-new.php6.09 ▲0.2085.39 ▼21.24
Media Library /wp-admin/upload.php3.41 ▲0.1844.55 ▲7.80
All Contract Addresses /wp-admin/edit.php?post_type=contract_address3.4538.47
Settings /wp-admin/edit.php?post_type=contract_address&page=wtwmain_settings3.3836.29
Add New /wp-admin/post-new.php?post_type=contract_address3.4649.17

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 20 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

pl8app custom bep20 token widget: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,930 ▲16913.52 ▼0.458.68 ▲6.0841.68 ▼3.13
Dashboard /wp-admin2,237 ▲575.52 ▼0.1090.39 ▲2.0173.49 ▲27.48
Posts /wp-admin/edit.php2,217 ▲1172.00 ▲0.0033.39 ▼5.7133.64 ▼4.70
Add New Post /wp-admin/post-new.php1,568 ▲4222.95 ▼0.65679.02 ▼0.82153.77 ▲90.17
Media Library /wp-admin/upload.php1,442 ▲424.11 ▼0.13109.68 ▲3.5178.48 ▲35.42
All Contract Addresses /wp-admin/edit.php?post_type=contract_address1,1001.9330.6627.96
Settings /wp-admin/edit.php?post_type=contract_address&page=wtwmain_settings8602.0024.4231.04
Add New /wp-admin/post-new.php?post_type=contract_address1,7753.5761.1681.18

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
  • The plugin did not uninstall gracefully
    • > Warning in wp-includes/class-wp-hook.php+310
    call_user_func_array() expects parameter 1 to be a valid callback, function 'plugin_uninstall' not found or invalid function name
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 8× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_Action() in wp-content/plugins/pl8app-custom-bep20-token-widget/modules/scripts.php:73
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_Action() in wp-content/plugins/pl8app-custom-bep20-token-widget/modules/meta_box.php:93
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_die() in wp-content/plugins/pl8app-custom-bep20-token-widget/wp-token-widget.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/pl8app-custom-bep20-token-widget/modules/cpt.php:27
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/pl8app-custom-bep20-token-widget/modules/shortcodes.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_Action() in wp-content/plugins/pl8app-custom-bep20-token-widget/modules/settings.php:156
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pl8app-custom-bep20-token-widget/modules/ajax.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/pl8app-custom-bep20-token-widget/modules/hooks.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 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
7 plugin tags: cryptocurrency price, crypto, custom bep20 token, cryptocurrency, cryptocurrency price widget...

pl8app-custom-bep20-token-widget/wp-token-widget.php 92% from 13 tests

The entry point to "pl8app custom bep20 token widget" version 1.2 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("pl8app-custom-bep20-token-widget.php" instead of "wp-token-widget.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin9,184 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
CSS3578,200
PHP1028253934
JavaScript121150

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity17.17
▷ Minimum class complexity1.00
▷ Maximum class complexity62.00
Average method complexity5.41
▷ Minimum method complexity1.00
▷ Maximum method complexity62.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods22
▷ Static methods00.00%
▷ Public methods22100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions763.64%
▷ Anonymous functions436.36%
Constants0
▷ Global constants00.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
3 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
modules/inc/assets/css/glyphicons-halflings-white.png8.57KB9.20KB0.00%
modules/inc/assets/css/glyphicons-halflings.png12.50KB10.35KB▼ 17.19%
modules/images/logo.png3.50KB1.31KB▼ 62.51%