78% liturgical-day-of-the-week

Code Review | Liturgical Day of the Week

WordPress plugin Liturgical Day of the Week scored78%from 54 tests.

About plugin

  • Plugin page: liturgical-day-of...
  • Plugin version: 1.0.4
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.4.1
  • WordPress version: 6.3.1
  • First release: Sep 18, 2021
  • Latest release: Nov 24, 2023
  • Number of updates: 10
  • Update frequency: every 79.7 days
  • Top authors: BearlyDoug (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /443 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼7.67ms] Passed 4 tests

A check of server-side resources used by Liturgical Day of the Week
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0133.70 ▼5.88
Dashboard /wp-admin3.32 ▼0.0344.19 ▼17.37
Posts /wp-admin/edit.php3.37 ▲0.0145.72 ▲0.45
Add New Post /wp-admin/post-new.php5.92 ▲0.0389.15 ▼5.98
Media Library /wp-admin/upload.php3.24 ▲0.0131.75 ▼1.45
Liturgical DotW /wp-admin/admin.php?page=ldotw3.7834.08
BD Plugins /wp-admin/admin.php?page=bearlydoug3.2134.33

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

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

Browser metrics Passed 4 tests

Liturgical Day of the Week: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,824 ▲6214.25 ▼0.431.55 ▼0.1338.23 ▼5.60
Dashboard /wp-admin2,230 ▲535.71 ▲0.0692.86 ▼5.0290.77 ▲49.12
Posts /wp-admin/edit.php2,138 ▲382.00 ▼0.0139.34 ▲3.0733.17 ▼6.60
Add New Post /wp-admin/post-new.php1,554 ▲2823.80 ▲0.94602.19 ▲6.46155.18 ▲97.75
Media Library /wp-admin/upload.php1,432 ▲324.22 ▲0.0794.16 ▼1.7572.41 ▲32.64
Liturgical DotW /wp-admin/admin.php?page=ldotw1,4271.8428.7248.79
BD Plugins /wp-admin/admin.php?page=bearlydoug1,4182.0125.3636.05

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • can_compress_scripts
    • db_upgraded
    • bdtzoffset
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 50% 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 everything seems fine, this is not an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 3× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/liturgical-day-of-the-week/includes/index.php
    • > /wp-content/plugins/liturgical-day-of-the-week/ldotw.php
    • > /wp-content/plugins/liturgical-day-of-the-week/images/index.php
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/liturgical-day-of-the-week/functions-bd.php:49

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 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
10 plugin tags: saints, religious colors, memorials, liturgical day of the week, liturgical...

liturgical-day-of-the-week/ldotw.php 77% from 13 tests

The main PHP script in "Liturgical Day of the Week" version 1.0.4 is automatically included on every request by WordPress
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("liturgical-day-of-the-week.php" instead of "ldotw.php")
  • Requires at least: Required version must be the same as the one declared in readme.txt ("5.5" instead of "5.2")
  • Description: Please keep the plugin description shorter than 140 characters (currently 473 characters long)

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
Everything looks great! No dangerous files found in this plugin1,186 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP474190637
CSS27840463
JavaScript24086

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
6 PNG files occupy 0.18MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/disable-gutenberg-plugin-icon.png16.22KB16.21KB0.05%
images/vimeo.png0.55KB0.67KB0.00%
images/delete.png0.96KB0.69KB▼ 27.68%
images/spacer.png0.27KB0.09KB▼ 64.60%
images/colorWheel.png2.04KB1.42KB▼ 30.46%