90% clean-expired-transients

Code Review | Clean Expired Transients

WordPress plugin Clean Expired Transients scored90%from 54 tests.

About plugin

  • Plugin page: clean-expired-tra...
  • Plugin version: 1.2
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.1
  • WordPress version: 6.3.1
  • First release: May 4, 2015
  • Latest release: Feb 24, 2019
  • Number of updates: 10
  • Update frequency: every 139.6 days
  • Top authors: dimadin (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,749 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.10ms] Passed 4 tests

A check of server-side resources used by Clean Expired Transients
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0039.87 ▼2.29
Dashboard /wp-admin3.31 ▲0.0044.66 ▼10.45
Posts /wp-admin/edit.php3.36 ▲0.0144.88 ▲6.49
Add New Post /wp-admin/post-new.php5.89 ▲0.0090.68 ▼5.23
Media Library /wp-admin/upload.php3.23 ▲0.0035.45 ▲1.57

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Clean Expired Transients
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.31 ▼1.444.72 ▲2.9144.51 ▲0.47
Dashboard /wp-admin2,206 ▲185.83 ▲0.0294.66 ▼26.0637.43 ▼6.45
Posts /wp-admin/edit.php2,089 ▲111.99 ▲0.0033.83 ▼6.7833.10 ▼3.50
Add New Post /wp-admin/post-new.php1,542 ▲2218.42 ▼4.64593.39 ▼15.2561.83 ▲4.59
Media Library /wp-admin/upload.php1,391 ▼04.21 ▼0.01100.64 ▼0.1544.19 ▼1.28

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
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests Passed 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 Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
2 plugin tags: transients, transient

clean-expired-transients/clean-expired-transients.php 92% from 13 tests

The entry point to "Clean Expired Transients" version 1.2 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Domain Path: The domain path is invalid: folder "/languages/" does not exist

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 plugin68 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1176868

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity2.33
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods133.33%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.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
There are no PNG files in this plugin