84% pubsubhubbub

Code Review | WebSub (FKA. PubSubHubbub)

WordPress plugin WebSub (FKA. PubSubHubbub) scored84%from 54 tests.

About plugin

  • Plugin page: pubsubhubbub
  • Plugin version: 3.1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.4
  • WordPress version: 6.3.1
  • First release: May 15, 2009
  • Latest release: Nov 29, 2023
  • Number of updates: 91
  • Update frequency: every 58.4 days
  • Top authors: pfefferle (64.84%)joshfraz (36.26%)

Code review

54 tests

User reviews

6 reviews

Install metrics

100,000+ active /1,668,744 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

This is a short check of server-side resources used by WebSub (FKA. PubSubHubbub)
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0137.09 ▼5.39
Dashboard /wp-admin3.32 ▲0.0245.79 ▼2.79
Posts /wp-admin/edit.php3.37 ▲0.0245.79 ▼2.61
Add New Post /wp-admin/post-new.php5.91 ▲0.0292.85 ▼8.01
Media Library /wp-admin/upload.php3.25 ▲0.0136.90 ▲2.86
WebSub /wp-admin/options-general.php?page=pubsubhubbub3.2530.99

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
db_upgraded
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for WebSub (FKA. PubSubHubbub)
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,794 ▲3214.72 ▲0.011.54 ▼0.1138.02 ▼6.62
Dashboard /wp-admin2,202 ▲385.62 ▲0.0390.79 ▼16.3142.12 ▼0.99
Posts /wp-admin/edit.php2,107 ▲251.96 ▼0.0338.36 ▲2.5635.72 ▼0.72
Add New Post /wp-admin/post-new.php1,529 ▲323.24 ▼0.08623.38 ▲9.9955.96 ▲4.62
Media Library /wp-admin/upload.php1,404 ▲44.21 ▲0.0499.10 ▲2.8042.22 ▲0.71
WebSub /wp-admin/options-general.php?page=pubsubhubbub9781.9723.1234.97

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means 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 take a closer look at the following
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pubsubhubbub/pubsubhubbub.php:66
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/pubsubhubbub/templates/settings-page.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/pubsubhubbub/includes/deprecated.php:41

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 errors were detected

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
  • Screenshots: Add an image for screenshot #1 (The WebSub Settings page allows you to define which hubs you want to use)
The official readme.txt is a good inspiration

pubsubhubbub/pubsubhubbub.php Passed 13 tests

This is the main PHP file of "WebSub (FKA. PubSubHubbub)" version 3.1.4, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
57 characters long description:
A better way to tell the world when your blog is updated.

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
No dangerous file extensions were detected332 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP883183332

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity6.50
▷ Minimum class complexity1.00
▷ Maximum class complexity17.00
Average method complexity2.47
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods15
▷ Static methods15100.00%
▷ Public methods15100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
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

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.05MB with 0.04MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png53.58KB14.66KB▼ 72.63%