84% wordpress-clock

Code Review | Worpress Clock

WordPress plugin Worpress Clock scored84%from 54 tests.

About plugin

  • Plugin page: wordpress-clock
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.3
  • WordPress version: 6.3.1
  • First release: Jan 14, 2012
  • Latest release: Nov 20, 2015
  • Number of updates: 6
  • Update frequency: every 234.5 days
  • Top authors: mervinpraison (100%)

Code review

54 tests

User reviews

1 review

Install metrics

90+ active /9,981 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.01MB] [CPU: ▼6.43ms] Passed 4 tests

This is a short check of server-side resources used by Worpress Clock
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0042.08 ▼1.63
Dashboard /wp-admin3.31 ▼0.0448.93 ▼14.31
Posts /wp-admin/edit.php3.36 ▲0.0046.63 ▼5.06
Add New Post /wp-admin/post-new.php5.89 ▲0.0095.67 ▼4.72
Media Library /wp-admin/upload.php3.23 ▲0.0037.66 ▲2.38

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Worpress Clock
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.72 ▼0.651.70 ▼0.2740.92 ▼2.12
Dashboard /wp-admin2,206 ▲154.83 ▼1.07105.55 ▼1.5240.05 ▲2.32
Posts /wp-admin/edit.php2,089 ▼32.00 ▲0.0339.29 ▲3.0035.64 ▼0.95
Add New Post /wp-admin/post-new.php1,533 ▲522.92 ▼0.15599.32 ▼57.3663.80 ▲10.29
Media Library /wp-admin/upload.php1,385 ▼04.18 ▼0.06102.27 ▼2.7445.43 ▼0.32

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts

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
Good news, no errors were detected

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
Almost there! Just fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/wordpress-clock/wp-clock.php:24

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Screenshots: Add an image for screenshot #1 (Wordpress Clock on Display)
Please take inspiration from this readme.txt

wordpress-clock/wp-clock.php 92% from 13 tests

The main PHP file in "Worpress Clock" ver. 1.1 adds more information about the plugin and also serves as the entry point for this plugin
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("wordpress-clock.php" instead of "wp-clock.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
There were no executable files found in this plugin23 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP17823

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.00
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%
Functions2
▷ Named functions2100.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
1 PNG file occupies 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png6.69KB3.79KB▼ 43.36%