74% dynamic-time

Code Review | Dynamic Time

WordPress plugin Dynamic Time scored74%from 54 tests.

About plugin

  • Plugin page: dynamic-time
  • Plugin version: 5.0.4
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.4
  • WordPress version: 6.3.1
  • First release: Mar 2, 2017
  • Latest release: Nov 27, 2023
  • Number of updates: 412
  • Update frequency: every 6.0 days
  • Top authors: rermis (100%)

Code review

54 tests

User reviews

20 reviews

Install metrics

300+ active /39,248 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼7.74ms] Passed 4 tests

Server-side resources used by Dynamic Time
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0740.14 ▼8.38
Dashboard /wp-admin3.38 ▲0.0848.00 ▼0.67
Posts /wp-admin/edit.php3.50 ▲0.1448.77 ▼1.44
Add New Post /wp-admin/post-new.php5.96 ▲0.0886.46 ▼20.48
Media Library /wp-admin/upload.php3.31 ▲0.0838.36 ▲1.13

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 10 new files
Database: 3 new tables, 7 new options
New tables
wp_time_user
wp_time_period
wp_time_entry
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_recent-comments
widget_theysaidso_widget
dyt_db_version

Browser metrics Passed 4 tests

An overview of browser requirements for Dynamic Time
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,823 ▲7614.73 ▲0.031.75 ▲0.1343.83 ▲2.55
Dashboard /wp-admin2,231 ▲605.60 ▼0.02100.74 ▼1.1043.43 ▲1.39
Posts /wp-admin/edit.php2,133 ▲331.99 ▼0.0240.10 ▲0.1037.26 ▲1.58
Add New Post /wp-admin/post-new.php1,552 ▲2623.05 ▼0.09651.06 ▼45.7653.95 ▲0.83
Media Library /wp-admin/upload.php1,433 ▲334.29 ▲0.0795.94 ▼11.5141.20 ▼4.24

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • Zombie tables were found after uninstall: 3 tables
    • wp_time_user
    • wp_time_period
    • wp_time_entry
  • Zombie WordPress options detected upon uninstall: 7 options
    • dyt_db_version
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options

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 | 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
Please fix the following items
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_js() in wp-content/plugins/dynamic-time/time_load_entries.php:31
    • > PHP Notice
      Undefined variable: entries in wp-content/plugins/dynamic-time/time_load_entries.php on line 6

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes: The official readme.txt is a good inspiration

dynamic-time/time_functions.php 92% from 13 tests

The main PHP script in "Dynamic Time" version 5.0.4 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("dynamic-time.php" instead of "time_functions.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin1,545 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP4161881,543
CSS1001
JavaScript1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.51
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%
Functions24
▷ Named functions24100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
2 compressed PNG files occupy 0.01MB
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/icon-256x256.png6.12KB6.43KB0.00%
assets/DynamicTime.png0.93KB0.96KB0.00%