66% shownotes

Code Review | Shownotes

WordPress plugin Shownotes scored66%from 54 tests.

About plugin

  • Plugin page: shownotes
  • Plugin version: 0.5.7
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3-5.7
  • WordPress version: 6.3.1
  • First release: May 10, 2013
  • Latest release: Dec 15, 2021
  • Number of updates: 59
  • Update frequency: every 53.3 days
  • Top authors: simonwaldherr (100%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active /3,334 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.36MB] [CPU: ▼3.08ms] Passed 4 tests

Server-side resources used by Shownotes
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.79 ▲0.3343.90 ▼1.57
Dashboard /wp-admin3.66 ▲0.3653.24 ▲2.95
Posts /wp-admin/edit.php3.77 ▲0.4251.60 ▲2.75
Add New Post /wp-admin/post-new.php6.27 ▲0.3887.13 ▼14.15
Media Library /wp-admin/upload.php3.58 ▲0.3537.43 ▲0.64
Shownotes /wp-admin/options-general.php?page=shownotes3.5336.30

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Shownotes
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,830 ▲4414.32 ▼0.241.70 ▼0.2743.31 ▲0.57
Dashboard /wp-admin2,207 ▲305.65 ▲0.0890.03 ▼2.9838.40 ▲0.59
Posts /wp-admin/edit.php2,115 ▲152.01 ▲0.0439.08 ▲2.7536.55 ▲0.03
Add New Post /wp-admin/post-new.php6,259 ▲4,73126.08 ▲2.92918.33 ▲219.0862.49 ▲7.34
Media Library /wp-admin/upload.php1,406 ▲64.25 ▲0.1095.56 ▼17.2843.16 ▼2.90
Shownotes /wp-admin/options-general.php?page=shownotes1,1072.0426.4542.03

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
Please fix the following items
  • This plugin does not fully uninstall, leaving 7 options in the database
    • shownotes_options
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 0% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=shownotes
    • > Notice in wp-content/plugins/shownotes/snsettings.php+181
    Undefined index: main_mode
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=shownotes
    • > Notice in wp-content/plugins/shownotes/snsettings.php+197
    Undefined index: main_tags_mode
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=shownotes
    • > Notice in wp-content/plugins/shownotes/snsettings.php+272
    Undefined index: css_id

SRP 0% from 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
The following issues need your attention
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/shownotes/api.php
  • 15× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Warning
      file_put_contents(./cache/3338247711100.mp4chaps.txt): failed to open stream: Permission denied in wp-content/plugins/shownotes/api.php on line 129
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/shownotes/snsettings.php:3
    • > PHP Notice
      Undefined index: proxytype in wp-content/plugins/shownotes/api.php on line 3
    • > PHP Warning
      count(): Parameter must be an array or an object that implements Countable in wp-content/plugins/shownotes/OSFphp/osf.php on line 656
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/shownotes/OSFphp/osf.php on line 657
    • > PHP Warning
      count(): Parameter must be an array or an object that implements Countable in wp-content/plugins/shownotes/OSFphp/osf.php on line 656
    • > PHP Notice
      Undefined index: mode in wp-content/plugins/shownotes/api.php on line 7
    • > PHP Notice
      Undefined index: preview in wp-content/plugins/shownotes/api.php on line 8
    • > PHP Notice
      Undefined index: shownotes in wp-content/plugins/shownotes/api.php on line 9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/shownotes/snsettings.php:3

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There are user-side issues you should fix
    • > GET request to /wp-admin/options-general.php?page=shownotes
    • > Network (severe)
    https://button.flattr.com/loader.js?mode=auto - Failed to load resource: the server responded with a status of 404 ()

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 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
These attributes need to be fixed:
  • Screenshots: Please add images for these screenshots: #1 (Options), #2 (Result (Block style)), #3 (Result (List style)), #4 (Result (Button style)), #5 (Meta box for OSF/MD input with Preview)
The official readme.txt might help

shownotes/shownotes.php Passed 13 tests

The entry point to "Shownotes" version 0.5.7 is a PHP file that has certain tags in its header comment area
46 characters long description:
Convert OSF-Shownotes to HTML for your Podcast

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected8,015 lines of code in 29 files:
LanguageFilesBlank linesComment linesLines of code
CSS1088703,889
PHP6210882,209
JavaScript656911,212
SVG100414
Markdown5860220
HTML17071

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.52
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions72
▷ Named functions7097.22%
▷ Anonymous functions22.78%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
225 PNG files occupy 0.73MB with 0.28MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
static/img/bwi/sharethis.png1.47KB1.33KB▼ 9.57%
static/img/bwi/bitcoin.png4.67KB1.39KB▼ 70.29%
static/img/bwi/git.png4.86KB1.32KB▼ 72.74%
static/img/bwi/email.png1.35KB1.07KB▼ 20.67%
static/img/bwi/w3.png1.94KB1.58KB▼ 18.69%