89% advanced-tag-rule

Code Review | Advanced Tag Rule

WordPress plugin Advanced Tag Rule scored89%from 54 tests.

About plugin

  • Plugin page: advanced-tag-rule
  • Plugin version: 1.1.9
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3-6.3
  • WordPress version: 6.3.1
  • First release: Mar 25, 2015
  • Latest release: Aug 9, 2023
  • Number of updates: 17
  • Update frequency: every 180.0 days
  • Top authors: BigTonny (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /1,425 total downloads


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.06MB] [CPU: ▼6.84ms] Passed 4 tests

Analyzing server-side resources used by Advanced Tag Rule
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0635.57 ▼6.45
Dashboard /wp-admin3.37 ▲0.0651.08 ▼1.00
Posts /wp-admin/edit.php3.42 ▲0.0653.12 ▼2.71
Add New Post /wp-admin/post-new.php5.97 ▲0.0885.15 ▼17.18
Media Library /wp-admin/upload.php3.29 ▲0.0638.45 ▼0.98
Tag Rules /wp-admin/options-general.php?page=atr-page3.2632.47

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

This is 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 /2,797 ▲3614.34 ▲0.052.02 ▲0.1742.94 ▲0.35
Dashboard /wp-admin2,200 ▲265.61 ▼0.0789.22 ▼0.1739.03 ▼6.02
Posts /wp-admin/edit.php2,108 ▲52.02 ▲0.0437.33 ▼3.8135.67 ▼0.60
Add New Post /wp-admin/post-new.php1,533 ▼1122.99 ▲4.67642.81 ▲6.9960.82 ▲15.17
Media Library /wp-admin/upload.php1,405 ▲54.21 ▼0.04103.72 ▼3.6144.95 ▼0.35
Tag Rules /wp-admin/options-general.php?page=atr-page7862.0324.0925.89

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests Passed 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 Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found


Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Add rule for tag), #2 (Manage rules: add, edit, remove and save.)
The official readme.txt might help

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

The main file in "Advanced Tag Rule" v. 1.1.9 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Main file name: The principal plugin file should be the same as 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 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin400 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PO File2305898

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity53.00
▷ Minimum class complexity53.00
▷ Maximum class complexity53.00
Average method complexity4.71
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods17.14%
▷ Public methods1178.57%
▷ Protected methods00.00%
▷ Private methods321.43%
▷ 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

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected