89% lunite-tunnel

Code Review | Lunite Tunnel

WordPress plugin Lunite Tunnel scored89%from 54 tests.

About plugin

  • Plugin page: lunite-tunnel
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-5.8.1
  • WordPress version: 6.3.1
  • First release: Oct 15, 2020
  • Latest release: Sep 10, 2021
  • Number of updates: 5
  • Update frequency: every 66.2 days
  • Top authors: kerasl (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /341 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼5.20ms] Passed 4 tests

Analyzing server-side resources used by Lunite Tunnel
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0040.12 ▼2.80
Dashboard /wp-admin3.31 ▲0.0046.36 ▼2.39
Posts /wp-admin/edit.php3.36 ▲0.0044.39 ▼6.14
Add New Post /wp-admin/post-new.php5.89 ▲0.0081.93 ▼6.65
Media Library /wp-admin/upload.php3.23 ▲0.0032.65 ▼5.19

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Lunite Tunnel
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.34 ▼1.031.84 ▼0.2943.87 ▼0.14
Dashboard /wp-admin2,206 ▲185.90 ▲1.04102.45 ▼15.9243.34 ▼2.91
Posts /wp-admin/edit.php2,089 ▲32.06 ▲0.0434.97 ▼2.8436.36 ▼1.01
Add New Post /wp-admin/post-new.php1,514 ▼2417.75 ▼5.54663.42 ▼15.8865.23 ▼1.44
Media Library /wp-admin/upload.php1,388 ▼04.17 ▲0.0194.99 ▼16.5942.22 ▼5.60

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes:
  • Donate link: Please fix this invalid url: "'https://github.com/keshansandeepa'"
The official readme.txt might help

lunite-tunnel/lunite-tunnel.php 92% from 13 tests

The principal PHP file in "Lunite Tunnel" v. 1.0.0 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Requires at least: The required version number did not match the one declared in readme.txt ("5.1" instead of "5.2")

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
Success! There were no dangerous files found in this plugin681 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP10102243436
CSS192132245

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity3.14
▷ Minimum class complexity1.00
▷ Maximum class complexity7.00
Average method complexity1.39
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods38
▷ Static methods25.26%
▷ Public methods2052.63%
▷ Protected methods615.79%
▷ Private methods1231.58%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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
1 PNG file occupies 0.05MB with 0.04MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-1.png49.85KB13.32KB▼ 73.29%