78% taxoclean

Code Review | Taxoclean

WordPress plugin Taxoclean scored78%from 54 tests.

About plugin

  • Plugin page: taxoclean
  • Plugin version: 1.0.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.2.2
  • WordPress version: 6.3.1
  • First release: Aug 10, 2023
  • Latest release: Aug 10, 2023
  • Number of updates: 3
  • Update frequency: every 19.0 days
  • Top authors: artwhere (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /80 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.23MB] [CPU: ▼7.81ms] Passed 4 tests

A check of server-side resources used by Taxoclean
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.67 ▲0.2039.03 ▼3.70
Dashboard /wp-admin3.60 ▲0.2651.20 ▼14.15
Posts /wp-admin/edit.php3.65 ▲0.3057.49 ▲11.88
Add New Post /wp-admin/post-new.php6.12 ▲0.2490.94 ▼6.93
Media Library /wp-admin/upload.php3.46 ▲0.2440.74 ▼6.44
About /wp-admin/admin.php?page=taxoclean_a5.3450.63
Ignored terms /wp-admin/admin.php?page=taxoclean_l_ignores5.3054.12
Orphans /wp-admin/admin.php?page=taxoclean_o4.1237.70
Settings /wp-admin/admin.php?page=taxoclean_s5.3953.58
Lookalikes /wp-admin/admin.php?page=taxoclean_l4.1238.24

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 442 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Taxoclean
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲6714.37 ▲0.121.68 ▼0.2645.62 ▲0.72
Dashboard /wp-admin2,231 ▲515.55 ▼0.1486.32 ▼10.7239.03 ▼3.80
Posts /wp-admin/edit.php2,142 ▲422.03 ▲0.0139.64 ▼2.5137.78 ▼2.51
Add New Post /wp-admin/post-new.php1,562 ▲3623.33 ▲5.62679.10 ▼16.7257.05 ▼2.03
Media Library /wp-admin/upload.php1,439 ▲424.22 ▼0.0295.45 ▼31.7046.31 ▼6.92
About /wp-admin/admin.php?page=taxoclean_a9192.0124.2230.39
Ignored terms /wp-admin/admin.php?page=taxoclean_l_ignores8662.0523.7328.85
Orphans /wp-admin/admin.php?page=taxoclean_o8922.0624.7428.73
Settings /wp-admin/admin.php?page=taxoclean_s1,0122.0525.0526.53
Lookalikes /wp-admin/admin.php?page=taxoclean_l8872.0529.8230.71

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=taxoclean_o
    • > Notice in wp-content/plugins/taxoclean/includes/tabs/taxoclean_o.php+23
    Trying to get property 'count' of non-object
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=taxoclean_l
    • > Warning in wp-content/plugins/taxoclean/vendor/twig/twig/src/Environment.php(418) : eval()'d code+78
    Division by zero
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=taxoclean_l
    • > Warning in wp-content/plugins/taxoclean/vendor/twig/twig/src/Environment.php(418) : eval()'d code+45
    range(): Invalid range supplied: start=0 end=inf
    • > GET request to /wp-admin/admin.php?page=taxoclean_l
    • > Warning in wp-content/plugins/taxoclean/includes/tabs/taxoclean_l.php+127
    array_slice() expects parameter 1 to be array, object given
    • > GET request to /wp-admin/admin.php?page=taxoclean_l
    • > Warning in wp-content/plugins/taxoclean/includes/tabs/taxoclean_l.php+142
    Invalid argument supplied for foreach()

SRP 50% from 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
Please take a closer look at the following
  • 151× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\\Expression\\Binary\\AbstractBinary' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/Node/Expression/Binary/NotEqualBinary.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function taxoclean_get_translations() in wp-content/plugins/taxoclean/includes/wp_add_to_menu.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\\Expression\\TestExpression' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/Node/Expression/Test/EvenTest.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\ode' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/Node/BlockNode.php:22
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\\TokenParser\\AbstractTokenParser' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/TokenParser/FlushTokenParser.php:22
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\\PrintNode' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/Node/SandboxedPrintNode.php:28
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\\Expression\\AbstractExpression' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/Node/Expression/Unary/AbstractUnary.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\ode' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/Node/PrintNode.php:23
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\\Expression\\Unary\\AbstractUnary' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/Node/Expression/Unary/NegUnary.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\\TokenParser\\AbstractTokenParser' not found in wp-content/plugins/taxoclean/vendor/twig/twig/src/TokenParser/UseTokenParser.php:31

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Screenshots: These screenshots require images: #1 (Orphan mode), #2 (Lookalike mode)
You can look at the official readme.txt

taxoclean/taxoclean.php Passed 13 tests

The main file in "Taxoclean" v. 1.0.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
36 characters long description:
Helps you to cleanup your taxonomies

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin20,207 lines of code in 421 files:
LanguageFilesBlank linesComment linesLines of code
PHP3903,8605,15217,601
PO File53003301,186
JSON600521
Twig12520512
CSS190169
YAML3490169
Markdown321039
reStructuredText18510

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity5.14
▷ Minimum class complexity1.00
▷ Maximum class complexity166.00
Average method complexity2.73
▷ Minimum method complexity1.00
▷ Maximum method complexity33.00
Code structure
Namespaces27
Interfaces14
Traits0
Classes349
▷ Abstract classes113.15%
▷ Concrete classes33896.85%
▷ Final classes5215.38%
Methods886
▷ Static methods859.59%
▷ Public methods75485.10%
▷ Protected methods586.55%
▷ Private methods748.35%
Functions195
▷ Named functions16986.67%
▷ Anonymous functions2613.33%
Constants61
▷ Global constants1118.03%
▷ Class constants5081.97%
▷ Public constants4998.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
3 PNG files occupy 0.65MB with 0.45MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-1.png25.17KB12.14KB▼ 51.79%
assets/robot.png609.69KB131.46KB▼ 78.44%
assets/screenshot-2.png30.34KB6.34KB▼ 79.11%