84% thunder-port

Code Review | Thunder Port

WordPress plugin Thunder Port scored84%from 54 tests.

About plugin

  • Plugin page: thunder-port
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-4.6.1
  • WordPress version: 6.3.1
  • First release: Jan 1, 2016
  • Latest release: Nov 7, 2016
  • Number of updates: 38
  • Update frequency: every 8.2 days
  • Top authors: vividlteam (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /521 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.02MB] [CPU: ▼5.73ms] Passed 4 tests

This is a short check of server-side resources used by Thunder Port
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.47 ▼8.98
Dashboard /wp-admin3.33 ▲0.0247.50 ▲1.59
Posts /wp-admin/edit.php3.44 ▲0.0846.30 ▲0.20
Add New Post /wp-admin/post-new.php5.90 ▲0.0290.46 ▼14.27
Media Library /wp-admin/upload.php3.25 ▲0.0233.85 ▲0.13
thunder_port /wp-admin/admin.php?page=thunder_port_detail3.2128.57

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 58 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Thunder Port
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,840 ▲10513.41 ▼1.344.30 ▲2.3840.07 ▼11.37
Dashboard /wp-admin2,224 ▲394.93 ▼0.9899.99 ▼10.0478.73 ▲34.21
Posts /wp-admin/edit.php2,104 ▲152.14 ▲0.1435.47 ▼6.3232.01 ▼5.18
Add New Post /wp-admin/post-new.php1,535 ▲2123.22 ▲5.29763.90 ▲159.9956.60 ▼0.64
Media Library /wp-admin/upload.php1,403 ▲184.12 ▼0.0896.53 ▼3.8345.12 ▲0.87
thunder_port /wp-admin/admin.php?page=thunder_port_detail7762.0123.7620.60

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
  • 1× 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/thunder-port/thunder_port.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
3 plugin tags: plugin support, quick search, wordpress plugin support

thunder-port/thunder_port.php 92% from 13 tests

"Thunder Port" version 1.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("thunder-port.php" instead of "thunder_port.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin9,306 lines of code in 38 files:
LanguageFilesBlank linesComment linesLines of code
CSS586353,078
PHP25864222,414
Sass1328241,520
LESS1328341,510
SVG100640
JavaScript3176143
JSON1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity164.50
▷ Minimum class complexity131.00
▷ Maximum class complexity198.00
Average method complexity4.85
▷ Minimum method complexity1.00
▷ Maximum method complexity57.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods85
▷ Static methods11.18%
▷ Public methods6981.18%
▷ Protected methods1618.82%
▷ Private methods00.00%
Functions26
▷ Named functions26100.00%
▷ Anonymous functions00.00%
Constants21
▷ Global constants21100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
8 PNG files occupy 0.33MB with 0.21MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-3.png82.37KB21.34KB▼ 74.09%
assets/screenshot-1.png71.17KB19.48KB▼ 72.63%
img/thunder-logo.png6.59KB3.79KB▼ 42.58%
img/logo16.png1.44KB0.45KB▼ 68.61%
img/Thunderport_square_logo.png1.48KB0.47KB▼ 68.10%