10% recent-featured-posts-widget

Code Review | Recent & Featured Posts Widget

WordPress plugin Recent & Featured Posts Widget scored10%from 54 tests.

About plugin

  • Plugin page: recent-featured-p...
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-4.4.2
  • WordPress version: 6.3.1
  • First release: Aug 6, 2015
  • Latest release: Feb 12, 2016
  • Number of updates: 6
  • Update frequency: every 31.7 days
  • Top authors: graysea (100%)

Code review

54 tests

User reviews

1 review

Install metrics

400+ active /5,195 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
You still need to fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/recent-featured-posts-widget/recent-featured-posts-widget.php+19
    Function create_function() is deprecated

Server metrics [RAM: ▼1.75MB] [CPU: ▼55.38ms] Passed 4 tests

This is a short check of server-side resources used by Recent & Featured Posts Widget
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.23 ▼1.234.63 ▼39.03
Dashboard /wp-admin2.25 ▼1.055.94 ▼50.60
Posts /wp-admin/edit.php2.25 ▼1.106.51 ▼42.03
Add New Post /wp-admin/post-new.php2.25 ▼3.635.48 ▼89.85
Media Library /wp-admin/upload.php2.25 ▼0.985.41 ▼29.92

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 4 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_recent-posts
widget_rfpw_widget
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Recent & Featured Posts Widget
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.24 ▼0.131.60 ▼0.0541.16 ▼2.36
Dashboard /wp-admin2,198 ▲215.57 ▼0.0585.39 ▼10.1138.35 ▼3.16
Posts /wp-admin/edit.php2,100 ▼02.00 ▲0.0540.38 ▲3.9936.65 ▲2.04
Add New Post /wp-admin/post-new.php1,534 ▲818.15 ▼4.98622.64 ▼61.5072.00 ▲18.86
Media Library /wp-admin/upload.php1,403 ▲64.21 ▲0.00101.60 ▲0.0345.10 ▲1.07

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • This plugin cannot be uninstalled
    • > Deprecated in wp-content/plugins/recent-featured-posts-widget/recent-featured-posts-widget.php+19
    Function create_function() is deprecated
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_rfpw_widget
    • db_upgraded
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
  • Tags: You are using too many tags: 15 tag instead of maximum 10
You can take inspiration from this readme.txt

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

The principal PHP file in "Recent & Featured Posts Widget" v. 1.1.0 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Text Domain: The text domain should only use lowercase characters and dashes

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
There were no executable files found in this plugin424 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP17276360
CSS111064

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity70.00
▷ Minimum class complexity70.00
▷ Maximum class complexity70.00
Average method complexity5.20
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods116.67%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions00.00%
▷ Anonymous functions2100.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
No PNG files were detected