84% jonradio-perpetual-calendar

Code Review | Perpetual Calendar Infinite Day of Week Calculator

WordPress plugin Perpetual Calendar Infinite Day of Week Calculator scored84%from 54 tests.

About plugin

  • Plugin page: jonradio-perpetua...
  • Plugin version: 3.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.8
  • WordPress version: 6.3.1
  • First release: Jun 16, 2012
  • Latest release: Aug 30, 2023
  • Number of updates: 62
  • Update frequency: every 66.0 days
  • Top authors: adiant (72.58%)dgewirtz (29.03%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,600 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

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

This is a short check of server-side resources used by Perpetual Calendar Infinite Day of Week Calculator
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0240.81 ▲2.32
Dashboard /wp-admin3.37 ▲0.0751.57 ▼8.33
Posts /wp-admin/edit.php3.42 ▲0.0749.35 ▼3.24
Add New Post /wp-admin/post-new.php5.95 ▲0.0793.77 ▲0.12
Media Library /wp-admin/upload.php3.30 ▲0.0737.76 ▲0.55
Perpetual Calendar plugin /wp-admin/options-general.php?page=jr_pc_settings3.2635.38

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 14 new files
Database: no new tables, 8 new options
New WordPress options
jr_pc_settings
can_compress_scripts
jr_pc_internal_settings
db_upgraded
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

Perpetual Calendar Infinite Day of Week Calculator: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.75 ▲0.071.89 ▼0.3842.38 ▲0.34
Dashboard /wp-admin2,202 ▲255.63 ▲0.0490.86 ▼10.9240.47 ▼0.28
Posts /wp-admin/edit.php2,104 ▲42.06 ▲0.0540.16 ▲0.7035.22 ▼2.47
Add New Post /wp-admin/post-new.php1,549 ▼623.13 ▲4.74652.74 ▼13.5356.56 ▲6.50
Media Library /wp-admin/upload.php1,404 ▲44.27 ▲0.09113.95 ▲10.5953.55 ▲12.22
Perpetual Calendar plugin /wp-admin/options-general.php?page=jr_pc_settings1,5492.2029.6244.22

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

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
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/jonradio-perpetual-calendar/includes/admin.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/jonradio-perpetual-calendar/includes/public.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that need to be fixed: Please take inspiration from this readme.txt

jonradio-perpetual-calendar/jonradio-perpetual-calendar.php 92% from 13 tests

Analyzing the main PHP file in "Perpetual Calendar Infinite Day of Week Calculator" version 3.0.1
It is important to fix the following:
  • Description: The description should be shorter than 140 characters (currently 276 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
No dangerous file extensions were detected1,471 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP5813361,050
PO File188152421

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.35
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%
Functions31
▷ Named functions31100.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
No PNG files were detected