10% bait-stream

Code Review | Bait Stream for Twitch TV

WordPress plugin Bait Stream for Twitch TV scored10%from 54 tests.

About plugin

  • Plugin page: bait-stream
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.3.1
  • WordPress version: 6.3.1
  • First release: Sep 22, 2015
  • Latest release: Sep 23, 2015
  • Number of updates: 11
  • Update frequency: N/A
  • Top authors: pcgamergirl (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,498 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
It is recommended to fix the following installer errors
  • This plugin did not install gracefully
    • > Parse error in wp-content/plugins/bait-stream/baitStream.php+102
    syntax error, unexpected end of file

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

Analyzing server-side resources used by Bait Stream for Twitch TV
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0042.97 ▲0.53
Dashboard /wp-admin3.31 ▲0.0049.83 ▼4.14
Posts /wp-admin/edit.php3.36 ▲0.0055.05 ▲5.04
Add New Post /wp-admin/post-new.php5.89 ▲0.0087.50 ▼19.76
Media Library /wp-admin/upload.php3.23 ▲0.0036.04 ▼8.01

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Bait Stream for Twitch TV
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.26 ▼0.491.66 ▼0.0642.61 ▼3.99
Dashboard /wp-admin2,198 ▲185.66 ▼0.0686.94 ▼5.1939.80 ▼6.24
Posts /wp-admin/edit.php2,100 ▼02.00 ▲0.0138.30 ▲1.5333.20 ▼5.61
Add New Post /wp-admin/post-new.php1,526 ▼817.73 ▼5.31666.71 ▼41.3753.01 ▼10.78
Media Library /wp-admin/upload.php1,403 ▲34.22 ▼0.0197.06 ▼18.6447.22 ▼0.76

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/bait-stream/pages/settings.php:3
    • > PHP Parse error
      syntax error, unexpected end of file in wp-content/plugins/bait-stream/baitStream.php on line 102

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that require attention:
  • Tags: You are using too many tags: 12 tag instead of maximum 10
Please take inspiration from this readme.txt

bait-stream/baitStream.php 92% from 13 tests

"Bait Stream for Twitch TV" version 1.0.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("bait-stream.php" instead of "baitStream.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected173 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP2312283
CSS19075
JavaScript10215

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.19
Average class complexity3.00
▷ Minimum class complexity3.00
▷ Maximum class complexity3.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
3 PNG files occupy 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/closeButton.png1.62KB0.53KB▼ 67.35%
images/background.png0.90KB0.09KB▼ 89.71%
images/taTwitchLogo.png5.92KB2.76KB▼ 53.42%