10% a-year-ago-today

Code Review | A Year Ago Today

WordPress plugin A Year Ago Today scored10%from 54 tests.

About plugin

  • Plugin page: a-year-ago-today
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-3.5.1
  • WordPress version: 6.3.1
  • First release: Feb 19, 2013
  • Latest release: Feb 20, 2013
  • Number of updates: 7
  • Update frequency: every 0.3 days
  • Top authors: jerimiw (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,651 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
  • Install procedure had errors
    • > Deprecated in wp-content/plugins/a-year-ago-today/year_ago.php+19
    Methods with the same name as their class will not be constructors in a future version of PHP; jaw_year_ago_my_info has a deprecated constructor

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

This is a short check of server-side resources used by A Year Ago Today
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.07 ▼1.404.29 ▼42.30
Dashboard /wp-admin2.09 ▼1.265.86 ▼59.50
Posts /wp-admin/edit.php2.09 ▼1.275.84 ▼46.63
Add New Post /wp-admin/post-new.php2.09 ▼3.805.64 ▼85.77
Media Library /wp-admin/upload.php2.09 ▼1.146.36 ▼29.33

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 2 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
widget_jaw_year_ago_my_info
theysaidso_admin_options
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for A Year Ago Today
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.23 ▼0.121.93 ▲0.0939.65 ▼9.39
Dashboard /wp-admin2,198 ▲215.64 ▲0.0489.33 ▼15.9340.89 ▼4.85
Posts /wp-admin/edit.php2,097 ▼31.98 ▼0.0140.03 ▼0.6334.31 ▼2.61
Add New Post /wp-admin/post-new.php1,528 ▼623.29 ▲5.20704.17 ▲65.9458.22 ▼2.56
Media Library /wp-admin/upload.php1,394 ▼34.20 ▼0.0497.26 ▼6.7642.36 ▼3.76

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin cannot be uninstalled
    • > Deprecated in wp-content/plugins/a-year-ago-today/year_ago.php+19
    Methods with the same name as their class will not be constructors in a future version of PHP; jaw_year_ago_my_info has a deprecated constructor
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-posts
    • db_upgraded
    • widget_jaw_year_ago_my_info
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments

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
Even though no errors were found, 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× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/a-year-ago-today/year_ago.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
3 plugin tags: old posts, widget, sidebar

a-year-ago-today/year_ago.php 92% from 13 tests

The primary PHP file in "A Year Ago Today" version 1.0.2 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("a-year-ago-today.php" instead of "year_ago.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
Everything looks great! No dangerous files found in this plugin63 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP19963

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity2.25
▷ Minimum method complexity1.00
▷ Maximum method complexity4.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%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin