10% better-recent-posts-widget

Code Review | Better Recent Posts Widget (with thumbnails)

WordPress plugin Better Recent Posts Widget (with thumbnails) scored10%from 54 tests.

About plugin

  • Plugin page: better-recent-pos...
  • Plugin version: 1.1.11
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-6.3
  • WordPress version: 6.3.1
  • First release: May 15, 2011
  • Latest release: Jul 29, 2023
  • Number of updates: 36
  • Update frequency: every 123.8 days
  • Top authors: dgewirtz (72.22%)mordauk (30.56%)

Code review

54 tests

User reviews

3 reviews

Install metrics

800+ active /25,739 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
It is recommended to fix the following installer errors
  • The plugin cannot be installed
    • > Deprecated in wp-content/plugins/better-recent-posts-widget/better-recent-posts-widget.php+14
    Methods with the same name as their class will not be constructors in a future version of PHP; pippin_recent_posts has a deprecated constructor

Server metrics [RAM: ▼1.89MB] [CPU: ▼55.12ms] Passed 4 tests

Analyzing server-side resources used by Better Recent Posts Widget (with thumbnails)
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.10 ▼1.374.80 ▼39.57
Dashboard /wp-admin2.12 ▼1.196.13 ▼41.01
Posts /wp-admin/edit.php2.12 ▼1.246.99 ▼41.42
Add New Post /wp-admin/post-new.php2.12 ▼3.775.72 ▼98.48
Media Library /wp-admin/upload.php2.12 ▼1.116.96 ▼32.66

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Better Recent Posts Widget (with thumbnails)
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲4313.19 ▼1.404.04 ▲1.9439.51 ▼7.57
Dashboard /wp-admin2,206 ▲155.91 ▲1.03107.09 ▲0.7939.17 ▼0.70
Posts /wp-admin/edit.php2,092 ▲32.00 ▼0.0339.72 ▲2.9834.99 ▲0.77
Add New Post /wp-admin/post-new.php1,514 ▼2317.60 ▼5.75671.34 ▼16.3662.95 ▲6.57
Media Library /wp-admin/upload.php1,388 ▼34.21 ▲0.0493.56 ▼3.2242.70 ▼1.78

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • This plugin did not uninstall without warnings or errors
    • > Deprecated in wp-content/plugins/better-recent-posts-widget/better-recent-posts-widget.php+14
    Methods with the same name as their class will not be constructors in a future version of PHP; pippin_recent_posts has a deprecated constructor
  • Zombie WordPress options detected upon uninstall: 7 options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_pippin_recent_posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts

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
Good news, no errors were detected

SRP 50% 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 take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/better-recent-posts-widget/better-recent-posts-widget.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
10 plugin tags: featured thumbnails, multisite, featured images, post thumbnail, recent posts...

better-recent-posts-widget/better-recent-posts-widget.php Passed 13 tests

The main PHP script in "Better Recent Posts Widget (with thumbnails)" version 1.1.11 is automatically included on every request by WordPress
90 characters long description:
Provides a better recent posts widget, including thumbnails, category, and number options.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
There were no executable files found in this plugin138 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP11917138

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.07
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity2.20
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.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

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin