84% post-date-options

Code Review | Genesis Post Date

WordPress plugin Genesis Post Date scored84%from 54 tests.

About plugin

  • Plugin page: post-date-options
  • Plugin version: 2.2.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2-5.0.3
  • WordPress version: 6.3.1
  • First release: Jan 29, 2019
  • Latest release: Sep 19, 2019
  • Number of updates: 14
  • Update frequency: every 17.4 days
  • Top authors: abedor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /618 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▼0.69MB] [CPU: ▼17.37ms] Passed 4 tests

Server-side resources used by Genesis Post Date
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0147.62 ▲4.02
Dashboard /wp-admin3.31 ▲0.0150.30 ▼2.10
Posts /wp-admin/edit.php3.36 ▲0.0144.90 ▼5.46
Add New Post /wp-admin/post-new.php3.10 ▼2.7935.32 ▼62.75
Media Library /wp-admin/upload.php3.23 ▲0.0037.79 ▲0.84

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Genesis Post Date
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2813.05 ▼1.304.53 ▲2.7143.18 ▲0.75
Dashboard /wp-admin2,198 ▲215.57 ▲0.0094.03 ▲7.0042.63 ▲2.19
Posts /wp-admin/edit.php2,100 ▼01.95 ▼0.0334.55 ▼0.2435.04 ▲1.68
Add New Post /wp-admin/post-new.php6,255 ▲4,72725.97 ▲2.92911.38 ▲290.9973.08 ▲23.77
Media Library /wp-admin/upload.php1,403 ▲64.22 ▲0.02100.15 ▼4.0644.57 ▼3.17

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
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting 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 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/post-date-options/metabox.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
3 plugin tags: posts, date, current date

post-date-options/metabox.php 92% from 13 tests

The main PHP script in "Genesis Post Date" version 2.2.2 is automatically included on every request by WordPress
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("post-date-options.php" instead of "metabox.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected124 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1168124

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.26
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
There were not PNG files found in your plugin