73% flash-world-clock

Code Review | World Clock

WordPress plugin World Clock scored73%from 54 tests.

About plugin

  • Plugin page: flash-world-clock
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-6.0.1
  • WordPress version: 6.3.1
  • First release: Feb 17, 2010
  • Latest release: Aug 23, 2022
  • Number of updates: 69
  • Update frequency: every 66.3 days
  • Top authors: enclick (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

400+ active /28,516 total downloads

Benchmarks

Plugin footprint 65% 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: ▼1.89MB] [CPU: ▼61.36ms] Passed 4 tests

Server-side resources used by World Clock
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.11 ▼1.355.09 ▼37.70
Dashboard /wp-admin2.13 ▼1.215.58 ▼60.33
Posts /wp-admin/edit.php2.13 ▼1.227.71 ▼42.90
Add New Post /wp-admin/post-new.php2.13 ▼3.766.13 ▼104.49
Media Library /wp-admin/upload.php2.13 ▼1.105.96 ▼29.94

Server storage [IO: ▲0.17MB] [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: 9 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for World Clock
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.23 ▼0.182.06 ▼0.1744.12 ▼0.09
Dashboard /wp-admin2,198 ▲215.64 ▲0.0488.40 ▼6.3140.18 ▼7.20
Posts /wp-admin/edit.php2,100 ▼32.01 ▼0.0238.38 ▼3.4131.29 ▼4.73
Add New Post /wp-admin/post-new.php1,526 ▼517.66 ▼5.52679.63 ▲67.2556.20 ▼0.27
Media Library /wp-admin/upload.php1,400 ▼04.29 ▲0.0998.02 ▼6.1344.02 ▼4.09

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin cannot be uninstalled
    • > User deprecated in wp-includes/functions.php+5453
    Function register_sidebar_widget is deprecated since version 2.8.0! Use wp_register_sidebar_widget() instead.
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • 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
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
The following issues need your attention
  • 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/flash-world-clock/world-clock.php:295

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

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need your attention:
  • Screenshots: Please add images for these screenshots: #1 (Vertical Digital clocks (white background)), #2 (Vertical Digital clocks (black background)), #3 (Vertical Analog clocks (navy blue background, yellow text)), #4 (Horizontal Analog clocks), #5 (Horizontal Digital clocks (white)), #6 (Horizontal Digital clocks (navy blue))
The official readme.txt might help

flash-world-clock/world-clock.php 85% from 13 tests

This is the main PHP file of "World Clock" version 1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("flash-world-clock.php" instead of "world-clock.php")
  • Description: The description should be shorter than 140 characters (currently 148 characters long)

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 detected345 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP213444345

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.22
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%
Functions10
▷ Named functions10100.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 are no PNG files in this plugin