94% wp-post-expires

Code Review | WP Post Expires

WordPress plugin WP Post Expires scored 94% from 54 tests.

About plugin

  • Plugin page: wp-post-expires
  • Plugin version: 1.2.5
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.5.3
  • WordPress version: 5.8.1
  • First release: Aug 16, 2016
  • Latest release: Nov 2, 2020
  • Number of updates: 21
  • Update frequency: every 73.3 days
  • Top authors: X-NicON (100%)

Code review

54 tests

User reviews

14 reviews

Install metrics

3,000+ active / 25,949 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.09MB] [CPU: ▼143.56ms] Passed 4 tests

An overview of server-side resources used by WP Post Expires
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.91 ▲0.1933.67 ▲13.11
Dashboard /wp-admin3.14 ▲0.0844.26 ▼5.27
Posts /wp-admin/edit.php3.22 ▲0.1245.04 ▲0.07
Add New Post /wp-admin/post-new.php5.51 ▲0.0890.74 ▼570.71
Media Library /wp-admin/upload.php3.08 ▲0.0833.51 ▲1.66

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 15 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for WP Post Expires
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,679 ▲8316.32 ▲0.6412.84 ▲1.7844.76 ▼0.03
Dashboard /wp-admin2,970 ▲365.90 ▼0.25147.31 ▼15.67105.36 ▼2.26
Posts /wp-admin/edit.php2,736 ▼32.70 ▼0.0168.55 ▼3.5884.59 ▼2.08
Add New Post /wp-admin/post-new.php1,725 ▲4221.70 ▲2.94284.09 ▼112.25118.85 ▲12.78
Media Library /wp-admin/upload.php1,807 ▼05.03 ▼0.00161.01 ▲8.04106.69 ▼10.37

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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
Almost there! Just fix the following items
  • 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/wp-post-expires/wp-post-expires.php:320

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found


Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: wordpress post expiry, expiration, expire, posts expiring, expired post

wp-post-expires/wp-post-expires.php 92% from 13 tests

The main file in "WP Post Expires" v. 1.2.5 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 154 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin410 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PO File2343896

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity49.00
▷ Minimum class complexity49.00
▷ Maximum class complexity49.00
Average method complexity3.40
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods420.00%
▷ Public methods1890.00%
▷ Protected methods00.00%
▷ Private methods210.00%
▷ Named functions00.00%
▷ Anonymous functions00.00%
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/css/images/ui-icons_454545_256x240.png4.27KB4.11KB▼ 3.78%