84% recent-posts-widget-extended

Code Review | Recent Posts Widget Extended

WordPress plugin Recent Posts Widget Extended scored84%from 54 tests.

About plugin

  • Plugin page: recent-posts-widg...
  • Plugin version: 2.0.2
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8-6.1
  • WordPress version: 6.3.1
  • First release: Dec 6, 2012
  • Latest release: Jul 31, 2023
  • Number of updates: 68
  • Update frequency: every 57.2 days
  • Top authors: satrya (95.59%)idenovasi (5.88%)

Code review

54 tests

User reviews

160 reviews

Install metrics

100,000+ active /1,662,531 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.02MB] [CPU: ▼4.51ms] Passed 4 tests

This is a short check of server-side resources used by Recent Posts Widget Extended
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0343.79 ▼0.38
Dashboard /wp-admin3.32 ▲0.0244.89 ▼7.54
Posts /wp-admin/edit.php3.44 ▲0.0848.34 ▼5.99
Add New Post /wp-admin/post-new.php5.90 ▲0.0284.15 ▼4.12
Media Library /wp-admin/upload.php3.24 ▲0.0236.30 ▲2.64

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Recent Posts Widget Extended
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,827 ▲7013.29 ▼1.092.01 ▲0.2644.66 ▲5.16
Dashboard /wp-admin2,205 ▲175.79 ▲0.90106.86 ▼8.2940.24 ▼7.03
Posts /wp-admin/edit.php2,091 ▼12.05 ▲0.0339.16 ▼4.4234.83 ▼1.72
Add New Post /wp-admin/post-new.php1,541 ▲718.45 ▼4.63612.47 ▼26.7748.92 ▲2.09
Media Library /wp-admin/upload.php1,393 ▲84.24 ▲0.06100.89 ▼27.6640.14 ▼11.42

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_rpwe_widget
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded

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
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/recent-posts-widget-extended/includes/compatibility.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/recent-posts-widget-extended/classes/class-rpwe-widget.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/recent-posts-widget-extended/includes/shortcode.php:41

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Tags: Please reduce the number of tags, currently 15 tag instead of maximum 10
Please take inspiration from this readme.txt

recent-posts-widget-extended/rpwe.php 92% from 13 tests

The principal PHP file in "Recent Posts Widget Extended" v. 2.0.2 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("recent-posts-widget-extended.php" instead of "rpwe.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin1,019 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP9203316826
CSS2301154
JavaScript291039

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity32.50
▷ Minimum class complexity32.00
▷ Maximum class complexity33.00
Average method complexity6.73
▷ Minimum method complexity1.00
▷ Maximum method complexity28.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods11
▷ Static methods19.09%
▷ Public methods981.82%
▷ Protected methods00.00%
▷ Private methods218.18%
Functions16
▷ Named functions1487.50%
▷ Anonymous functions212.50%
Constants3
▷ Global constants3100.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
There were not PNG files found in your plugin