84% mp-recent-post-widget

Code Review | MP Recent Post Widget

WordPress plugin MP Recent Post Widget scored84%from 54 tests.

About plugin

  • Plugin page: mp-recent-post-wi...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-4.5.3
  • WordPress version: 6.3.1
  • First release: Aug 4, 2016
  • Latest release: Aug 3, 2016
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: MediumPixel (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,774 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.06MB] [CPU: ▼8.00ms] Passed 4 tests

A check of server-side resources used by MP Recent Post Widget
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0747.79 ▲4.52
Dashboard /wp-admin3.38 ▲0.0348.89 ▼18.90
Posts /wp-admin/edit.php3.49 ▲0.1450.56 ▼11.93
Add New Post /wp-admin/post-new.php5.96 ▲0.0789.08 ▼4.63
Media Library /wp-admin/upload.php3.30 ▲0.0737.73 ▲3.47
MP Recent Post /wp-admin/options-general.php?page=mp-recent-post-widget3.2731.60

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

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

Browser metrics Passed 4 tests

A check of browser resources used by MP Recent Post Widget
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲3314.48 ▲0.121.79 ▼0.3844.88 ▲2.55
Dashboard /wp-admin2,213 ▲314.84 ▼0.97115.84 ▼0.8742.44 ▼1.43
Posts /wp-admin/edit.php2,093 ▲72.04 ▲0.0339.67 ▼0.7335.63 ▼0.79
Add New Post /wp-admin/post-new.php1,517 ▼1617.42 ▼5.82705.03 ▲15.4555.72 ▲8.48
Media Library /wp-admin/upload.php1,395 ▲74.24 ▲0.03106.98 ▲3.7347.49 ▲4.74
MP Recent Post /wp-admin/options-general.php?page=mp-recent-post-widget8062.0325.8329.04

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_mp-recent-post
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, 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 fix the following items
  • 5× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/mp-recent-post-widget/includes/template-functions.php
    • > /wp-content/plugins/mp-recent-post-widget/includes/class-mp-recent-post-widget-settings.php
    • > /wp-content/plugins/mp-recent-post-widget/mp-recent-post-widget.php
    • > /wp-content/plugins/mp-recent-post-widget/includes/class-mp-recent-post-widget.php
    • > /wp-content/plugins/mp-recent-post-widget/templates/mp-recent-post-widget.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

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
5 plugin tags: widget, recent post widget, post meta, thumbnail, post

mp-recent-post-widget/mp-recent-post-widget.php Passed 13 tests

"MP Recent Post Widget" version 1.0.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
23 characters long description:
Recent Blog Post Widget

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 plugin342 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP511536317
CSS17123
Markdown1002

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity8.67
▷ Minimum class complexity5.00
▷ Maximum class complexity13.00
Average method complexity2.10
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods21
▷ Static methods00.00%
▷ Public methods21100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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