10% last-revision-widget

Code Review | Last Revision Date Widget

WordPress plugin Last Revision Date Widget scored10%from 54 tests.

About plugin

  • Plugin page: last-revision-widget
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.0
  • WordPress version: 6.3.1
  • First release: Nov 19, 2014
  • Latest release: Nov 19, 2014
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: alci1969 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /950 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Please fix the following installer errors
  • The plugin did not install without errors
    • > Deprecated in wp-content/plugins/last-revision-widget/last-revision-widget.php+31
    Methods with the same name as their class will not be constructors in a future version of PHP; LastRevisionDateWidget has a deprecated constructor

Server metrics [RAM: ▼1.93MB] [CPU: ▼62.78ms] Passed 4 tests

An overview of server-side resources used by Last Revision Date Widget
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.06 ▼1.404.45 ▼42.96
Dashboard /wp-admin2.08 ▼1.265.25 ▼58.78
Posts /wp-admin/edit.php2.08 ▼1.276.56 ▼47.13
Add New Post /wp-admin/post-new.php2.08 ▼3.805.09 ▼102.26
Media Library /wp-admin/upload.php2.08 ▼1.155.38 ▼32.73

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 3 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
widget_lastrevisiondatewidget
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Last Revision Date Widget
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲9013.32 ▼1.052.02 ▲0.3542.43 ▼4.74
Dashboard /wp-admin2,206 ▲154.84 ▼0.07112.43 ▲12.7842.73 ▼1.07
Posts /wp-admin/edit.php2,089 ▼02.05 ▲0.0337.78 ▲1.8836.52 ▼0.32
Add New Post /wp-admin/post-new.php1,531 ▲1723.30 ▲5.73683.36 ▼10.9162.86 ▲8.60
Media Library /wp-admin/upload.php1,382 ▼94.20 ▼0.0199.46 ▼0.5442.85 ▼3.86

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • This plugin cannot be uninstalled
    • > Deprecated in wp-content/plugins/last-revision-widget/last-revision-widget.php+31
    Methods with the same name as their class will not be constructors in a future version of PHP; LastRevisionDateWidget has a deprecated constructor
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_lastrevisiondatewidget
    • 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
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
Please take a closer look at the following
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/last-revision-widget/last-revision-widget.php:31

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

Often overlooked, readme.txt is one of the most important files in your plugin
7 plugin tags: date, sidebar, last, revision, page...

last-revision-widget/last-revision-widget.php Passed 13 tests

Analyzing the main PHP file in "Last Revision Date Widget" version 1.0.0
49 characters long description:
Show last revision date for the current page/post

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin48 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1162548

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.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

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected