Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Please fix the following installer errors
- Install procedure validation failed for this plugin
- > Deprecated in wp-content/plugins/lnd-for-wp/classes/qrdecoder/lib/common/BitMatrix.php+37
Array and string offset access syntax with curly braces is deprecated
Server metrics [RAM: ▼1.00MB] [CPU: ▼48.02ms] Passed 4 tests
An overview of server-side resources used by LND For WP
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.98 ▼0.48 | 9.94 ▼33.44 |
Dashboard /wp-admin | 3.00 ▼0.30 | 16.07 ▼36.60 |
Posts /wp-admin/edit.php | 3.00 ▼0.35 | 13.85 ▼34.28 |
Add New Post /wp-admin/post-new.php | 3.00 ▼2.88 | 12.15 ▼87.28 |
Media Library /wp-admin/upload.php | 3.00 ▼0.23 | 11.95 ▼33.90 |
Server storage [IO: ▲1.45MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 520 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
db_upgraded |
can_compress_scripts |
widget_recent-comments |
widget_recent-posts |
theysaidso_admin_options |
Browser metrics Passed 4 tests
This is an overview of browser requirements for LND For WP
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,935 ▲189 | 13.55 ▼0.82 | 6.69 ▲4.56 | 39.13 ▼9.87 |
Dashboard /wp-admin | 2,215 ▲27 | 5.91 ▼0.11 | 102.21 ▼14.11 | 87.93 ▲44.24 |
Posts /wp-admin/edit.php | 2,116 ▲27 | 2.03 ▼0.00 | 39.18 ▲1.66 | 33.71 ▼0.50 |
Add New Post /wp-admin/post-new.php | 1,528 ▼0 | 23.10 ▲4.93 | 647.09 ▼14.54 | 54.53 ▲1.85 |
Media Library /wp-admin/upload.php | 1,415 ▲30 | 4.26 ▲0.07 | 115.51 ▼7.88 | 47.20 ▼14.24 |
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
You still need to fix the following
- This plugin cannot be uninstalled
- > Deprecated in wp-content/plugins/lnd-for-wp/classes/qrdecoder/lib/common/BitMatrix.php+37
Array and string offset access syntax with curly braces is deprecated
- This plugin did not uninstall successfully, leaving 6 options in the database
- widget_theysaidso_widget
- theysaidso_admin_options
- widget_recent-comments
- widget_recent-posts
- db_upgraded
- can_compress_scripts
Smoke tests 50% 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)
Everything seems fine, however this is by no means an exhaustive test
SRP 0% 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
- 2× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/lnd-for-wp/classes/phpqrcode/index.php
- > /wp-content/plugins/lnd-for-wp/public/partials/lnd-for-wp-request-invoice-ajax.php
- 31× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/lnd-for-wp/admin/partials/lnd-for-wp-admin-wallet.php:14
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/lnd-for-wp/admin/partials/lnd-for-wp-admin-transactions.php:14
- > PHP Fatal error
Uncaught Error: Class 'Zxing\\LuminanceSource' not found in wp-content/plugins/lnd-for-wp/classes/qrdecoder/lib/GDLuminanceSource.php:13
- > PHP Fatal error
Uncaught Error: Class 'Zxing\\Binarizer' not found in wp-content/plugins/lnd-for-wp/classes/qrdecoder/lib/common/GlobalHistogramBinarizer.php:36
- > PHP Parse error
syntax error, unexpected end of file in wp-content/plugins/lnd-for-wp/admin/partials/lnd-for-wp-admin-channels.php on line 208
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/lnd-for-wp/admin/partials/lnd-for-wp-admin-display.php:14
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/lnd-for-wp/admin/partials/lnd-for-wp-admin-network.php:14
- > PHP Notice
Undefined variable: attributes in wp-content/plugins/lnd-for-wp/public/partials/lnd-for-wp-request-invoice-ajax.php on line 17
- > PHP Fatal error
Uncaught Error: Class 'Zxing\\ReaderException' not found in wp-content/plugins/lnd-for-wp/classes/qrdecoder/lib/NotFoundException.php:26
- > PHP Fatal error
Uncaught Error: Class 'Zxing\\LuminanceSource' not found in wp-content/plugins/lnd-for-wp/classes/qrdecoder/lib/PlanarYUVLuminanceSource.php:30
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: lightning, lnd, lightning network, bitcoin
lnd-for-wp/lnd-for-wp.php Passed 13 tests
The main PHP file in "LND For WP" ver. 0.1.2 adds more information about the plugin and also serves as the entry point for this plugin
29 characters long description:
Manage and use your LND node.
Code Analysis 5% from 3 tests
File types 0% from 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
It is important to fix the following items
- Do not distribute dangerous files with your plugin
- .bat - Batch File in Windows
- ☣ wp-content/plugins/lnd-for-wp/classes/phpqrcode/tools/merge.bat
- .bat - Batch File in Windows
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 92 | 3,266 | 5,463 | 13,490 |
CSS | 2 | 87 | 9 | 598 |
JavaScript | 2 | 79 | 39 | 205 |
Markdown | 1 | 10 | 0 | 22 |
Bourne Shell | 1 | 0 | 0 | 2 |
DOS Batch | 1 | 0 | 0 | 2 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.33 |
Average class complexity | 22.20 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 292.00 |
Average method complexity | 3.63 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 36.00 |
Code structure | ||
---|---|---|
Namespaces | 9 | |
Interfaces | 1 | |
Traits | 0 | |
Classes | 99 | |
▷ Abstract classes | 5 | 5.05% |
▷ Concrete classes | 94 | 94.95% |
▷ Final classes | 41 | 43.62% |
Methods | 817 | |
▷ Static methods | 179 | 21.91% |
▷ Public methods | 647 | 79.19% |
▷ Protected methods | 108 | 13.22% |
▷ Private methods | 62 | 7.59% |
Functions | 14 | |
▷ Named functions | 14 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 98 | |
▷ Global constants | 98 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
44 PNG files occupy 0.39MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
classes/phpqrcode/cache/frame_39.png | 0.26KB | 0.23KB | ▼ 9.85% |
classes/phpqrcode/cache/frame_35.png | 0.24KB | 0.21KB | ▼ 9.47% |
classes/phpqrcode/cache/frame_7.png | 0.18KB | 0.18KB | ▼ 0.53% |
lnd-for-wp-preview.png | 347.96KB | 139.29KB | ▼ 59.97% |
classes/phpqrcode/cache/frame_13.png | 0.21KB | 0.19KB | ▼ 5.24% |