82% mxr-easy-embed-wall

Code Review | Mixer Easy Embed Wall

WordPress plugin Mixer Easy Embed Wall scored 82% from 54 tests.

About plugin

  • Plugin page: mxr-easy-embed-wall
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-5.0
  • WordPress version: 5.8.1
  • First release: Jan 20, 2019
  • Latest release: Apr 14, 2019
  • Number of updates: 3
  • Update frequency: every 28.0 days
  • Top authors: j.burleigh1 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 879 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼139.62ms] Passed 4 tests

Server-side resources used by Mixer Easy Embed Wall
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.80 ▼0.0425.92 ▼8.29
Dashboard /wp-admin3.17 ▲0.1151.85 ▲5.76
Posts /wp-admin/edit.php3.28 ▲0.1742.98 ▲1.51
Add New Post /wp-admin/post-new.php5.53 ▲0.1090.24 ▼547.42
Media Library /wp-admin/upload.php3.11 ▲0.1034.52 ▼4.27
Easy Embed for Mixer (WALL) /wp-admin/options-general.php?page=mixer-wall3.0019.96

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 32 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Mixer Easy Embed Wall
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,796 ▲20016.48 ▲0.8912.57 ▲3.9844.41 ▼1.41
Dashboard /wp-admin2,975 ▲446.05 ▲0.11129.93 ▼7.43115.68 ▼0.38
Posts /wp-admin/edit.php2,744 ▲82.68 ▼0.0170.00 ▲4.5488.51 ▼8.40
Add New Post /wp-admin/post-new.php1,503 ▲318.64 ▲0.01382.97 ▲35.16107.70 ▲3.39
Media Library /wp-admin/upload.php1,815 ▲115.03 ▲0.04142.01 ▼6.71125.34 ▼1.77
Easy Embed for Mixer (WALL) /wp-admin/options-general.php?page=mixer-wall1,3242.3456.6473.37

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Uninstaller ran successfully

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
  • 15 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=mixer-wall
    • > Notice in wp-content/plugins/mxr-easy-embed-wall/admin/partials/fields-output.php+36
    Trying to access array offset on value of type bool

SRP 0% 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
Please fix the following items
  • 3× PHP files output text when accessed directly:
    • > /wp-content/plugins/mxr-easy-embed-wall/public/partials/mixer-wall-public-display.php
    • > /wp-content/plugins/mxr-easy-embed-wall/admin/partials/mixer-wall-admin-display.php
    • > /wp-content/plugins/mxr-easy-embed-wall/templates/mixer-wall.php
  • 5× PHP files trigger server errors when accessed directly:
    • > PHP Notice
      Undefined variable: defaultTheme in wp-content/plugins/mxr-easy-embed-wall/templates/mixer-wall.php on line 1
    • > PHP Notice
      Undefined variable: id in wp-content/plugins/mxr-easy-embed-wall/templates/mixer-wall.php on line 1
    • > PHP Notice
      Undefined variable: id in wp-content/plugins/mxr-easy-embed-wall/templates/mixer-wall.php on line 1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/mxr-easy-embed-wall/public/partials/output.php:2
    • > PHP Notice
      Undefined variable: id in wp-content/plugins/mxr-easy-embed-wall/templates/mixer-wall.php on line 4

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration 93% 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
4 plugin tags: twitch, mixercom widget, mixercom, mixercom embed

mxr-easy-embed-wall/mixer-wall.php 85% from 13 tests

"Mixer Easy Embed Wall" version 1.0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("mxr-easy-embed-wall.php" instead of "mixer-wall.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected657 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PHP16145531370
JavaScript32745186
CSS211595
SVG1016

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity2.71
▷ Minimum class complexity1.00
▷ Maximum class complexity11.00
Average method complexity1.41
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods31
▷ Static methods26.45%
▷ Public methods2683.87%
▷ Protected methods00.00%
▷ Private methods516.13%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
4 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
public/img/300x169-placeholder.png19.55KB1.06KB▼ 94.60%
admin/img/twitch-rail.png7.07KB4.04KB▼ 42.93%
admin/img/twitch-player.png6.97KB4.26KB▼ 38.90%
admin/img/twitch-wall.png7.49KB4.16KB▼ 44.49%