79% advanced-tag-rule

Code Review | Advanced Tag Rule

WordPress plugin Advanced Tag Rule scored 79% from 54 tests.

About plugin

  • Plugin page: advanced-tag-rule
  • Plugin version: 1.1.8
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3-5.8.2
  • WordPress version: 5.9.2
  • First release: Mar 25, 2015
  • Latest release: Dec 16, 2021
  • Number of updates: 15
  • Update frequency: every 163.9 days
  • Top authors: BigTonny (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active / 942 total downloads


Plugin footprint 65% from 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.04MB] [CPU: ▼308.33ms] Passed 4 tests

Server-side resources used by Advanced Tag Rule
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.0757.71 ▲9.21
Dashboard /wp-admin3.48 ▲0.0735.22 ▲1.07
Posts /wp-admin/edit.php3.70 ▲0.0645.57 ▲2.04
Add New Post /wp-admin/post-new.php6.95 ▼0.0396.12 ▼1,237.75
Media Library /wp-admin/upload.php3.36 ▲0.0623.97 ▲1.31
Tag Rules /wp-admin/options-general.php?page=atr-page3.3324.42

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 13 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Advanced Tag Rule
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,772 ▲2815.87 ▲0.316.18 ▼0.392.25 ▲0.26
Dashboard /wp-admin2,901 ▲506.08 ▼0.08118.89 ▼20.83155.99 ▲5.32
Posts /wp-admin/edit.php2,697 ▲33.24 ▼0.1164.72 ▲2.18135.47 ▼6.47
Add New Post /wp-admin/post-new.php1,667 ▲616.15 ▲0.56407.74 ▼19.26163.00 ▲6.35
Media Library /wp-admin/upload.php1,708 ▲105.57 ▲0.08148.77 ▲0.99192.29 ▼5.31
Tag Rules /wp-admin/options-general.php?page=atr-page9692.4152.39102.34

Uninstaller [IO: ▲0.41MB] [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
  • The plugin did not uninstall gracefully
    • > Deprecated in wp-includes/class-wp-hook.php+307
    Non-static method ATR_Plugin::uninstall() should not be called statically
  • This plugin has failed uninstalling correctly, leaving 13 files (0.41MB) in the plugin directory
    • (new file) atr-plugin.php
    • (new file) lang/atr-plugin-ru_RU.po
    • (new file) 2.jpg
    • (new file) assets/js/admin.js
    • (new file) lang/atr-plugin-ru_RU.mo
    • (new file) 1.jpg
    • (new file) lang/atr-plugin-en_GB.mo
    • (new file) lang/atr-plugin-en_GB.po
    • (new file) assets/css/admin.css
    • (new file) lang/atr.pot
    • ...

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The SRP test was a success

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)
Everything seems fine, but this is not an exhaustive test


Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Screenshots: Add images for these screenshots: #1 (Add rule for tag), #2 (Manage rules: add, edit, remove and save.)
Please take inspiration from this readme.txt

advanced-tag-rule/atr-plugin.php 85% from 13 tests

The main PHP file in "Advanced Tag Rule" ver. 1.1.8 adds more information about the plugin and also serves as the entry point for this plugin
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("advanced-tag-rule.php" instead of "atr-plugin.php")
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected403 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PO File2305898

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity55.00
▷ Minimum class complexity55.00
▷ Maximum class complexity55.00
Average method complexity4.60
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods16.67%
▷ Public methods1280.00%
▷ Protected methods00.00%
▷ Private methods320.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

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin