83% podcast-feed-player-widget

Code Review | Podcast Feed Player Widget and Shortcode

WordPress plugin Podcast Feed Player Widget and Shortcode scored83%from 54 tests.

About plugin

  • Plugin page: podcast-feed-play...
  • Plugin version: 2.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.0-5.2.2
  • WordPress version: 6.3.1
  • First release: Sep 25, 2017
  • Latest release: Aug 13, 2019
  • Number of updates: 27
  • Update frequency: every 25.4 days
  • Top authors: douglaskarr (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

700+ active /10,594 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼2.46ms] Passed 4 tests

A check of server-side resources used by Podcast Feed Player Widget and Shortcode
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0140.73 ▼0.31
Dashboard /wp-admin3.31 ▲0.0148.66 ▲1.42
Posts /wp-admin/edit.php3.37 ▲0.0143.53 ▲0.16
Add New Post /wp-admin/post-new.php5.90 ▲0.0181.18 ▼8.69
Media Library /wp-admin/upload.php3.24 ▲0.0133.99 ▼0.99

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Podcast Feed Player Widget and Shortcode
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.37 ▲0.011.74 ▼0.2546.59 ▲0.13
Dashboard /wp-admin2,198 ▲245.63 ▲0.0296.16 ▼3.9242.72 ▲0.21
Posts /wp-admin/edit.php2,097 ▼31.98 ▼0.0135.07 ▼1.3435.50 ▼3.16
Add New Post /wp-admin/post-new.php1,526 ▼223.55 ▲0.58694.93 ▲11.7955.48 ▼7.88
Media Library /wp-admin/upload.php1,400 ▼04.17 ▼0.0295.10 ▼12.0442.04 ▼3.59

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 7 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_dkpp_podcast_widget
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/podcast-feed-player-widget/podcast-feed-player-widget.php:33
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/podcast-feed-player-widget/podcast-feed-player-widget.php on line 31
    • > PHP Warning
      Use of undefined constant WPINC - assumed 'WPINC' (this will throw an Error in a future version of PHP) in wp-content/plugins/podcast-feed-player-widget/podcast-feed-player-widget.php on line 31
    • > PHP Warning
      include_once(): Failed opening 'ABSPATHWPINC/feed.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/podcast-feed-player-widget/podcast-feed-player-widget.php on line 31
    • > PHP Warning
      include_once(ABSPATHWPINC/feed.php): failed to open stream: No such file or directory in wp-content/plugins/podcast-feed-player-widget/podcast-feed-player-widget.php on line 31

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need to be fixed:
  • Screenshots: Please add images for these screenshots: #1 (Widget Options), #2 (Widget Output)
  • Tags: Please delete some tags, you are using 26 tag instead of maximum 10
Please take inspiration from this readme.txt

podcast-feed-player-widget/podcast-feed-player-widget.php 85% from 13 tests

The main file in "Podcast Feed Player Widget and Shortcode" v. 2.2.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Description: The description should be shorter than 140 characters (currently 386 characters long)
  • Text Domain: The text domain name should consist of only dashes and lowercase characters

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
No dangerous file extensions were detected260 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP16228260

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity28.00
▷ Minimum class complexity28.00
▷ Maximum class complexity28.00
Average method complexity7.75
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.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
2 PNG files occupy 0.25MB with 0.18MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png195.40KB60.81KB▼ 68.88%
screenshot-1.png64.87KB18.11KB▼ 72.09%