84% taxonomy-terms-order

Code Review | Category Order and Taxonomy Terms Order

WordPress plugin Category Order and Taxonomy Terms Order scored84%from 54 tests.

About plugin

  • Plugin page: taxonomy-terms-order
  • Plugin version: 1.7.9
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-6.3
  • WordPress version: 6.3.1
  • First release: Sep 17, 2011
  • Latest release: Aug 11, 2023
  • Number of updates: 62
  • Update frequency: every 71.2 days
  • Top authors: nsp-code (100%)

Code review

54 tests

User reviews

155 reviews

Install metrics

500,000+ active /6,559,952 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.09MB] [CPU: ▼13.75ms] Passed 4 tests

Server-side resources used by Category Order and Taxonomy Terms Order
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0642.85 ▼4.59
Dashboard /wp-admin3.41 ▲0.0647.56 ▼20.72
Posts /wp-admin/edit.php3.52 ▲0.1751.19 ▼9.70
Add New Post /wp-admin/post-new.php6.01 ▲0.1287.97 ▼19.97
Media Library /wp-admin/upload.php3.33 ▲0.1039.72 ▲4.61
Taxonomy Order /wp-admin/edit.php?page=to-interface-post3.3135.43
Taxonomy Terms Order /wp-admin/options-general.php?page=to-options3.3036.40

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 16 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Category Order and Taxonomy Terms Order: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,802 ▲4114.75 ▲0.151.69 ▲0.0439.87 ▼2.69
Dashboard /wp-admin2,196 ▲165.55 ▼0.1286.58 ▼5.6069.22 ▲27.96
Posts /wp-admin/edit.php2,120 ▲172.07 ▲0.0735.44 ▼7.1633.08 ▼3.72
Add New Post /wp-admin/post-new.php1,539 ▲1323.09 ▼0.11712.63 ▲21.8054.47 ▼4.04
Media Library /wp-admin/upload.php1,410 ▲104.11 ▼0.1198.70 ▼14.2773.72 ▲25.27
Taxonomy Order /wp-admin/edit.php?page=to-interface-post8702.0430.1028.45
Taxonomy Terms Order /wp-admin/options-general.php?page=to-options9641.7824.9928.60

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
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Good news, no errors were detected

SRP 50% from 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
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/taxonomy-terms-order/taxonomy-terms-order.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Please fix the following attributes:
  • Screenshots: Add images for these screenshots: #1 (Category Order Interface.), #2 (Multiple Taxonomies Interface.)
The official readme.txt might help

taxonomy-terms-order/taxonomy-terms-order.php Passed 13 tests

The principal PHP file in "Category Order and Taxonomy Terms Order" v. 1.7.9 is loaded by WordPress automatically on each request
135 characters long description:
Order Categories and all custom taxonomies terms (hierarchically) and child terms using a Drag and Drop Sortable javascript capability.

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
Good job! No executable or dangerous file extensions detected679 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP619041529
PO File1313285
CSS19031
JSON10017
JavaScript12117

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.58
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.25
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions20
▷ Named functions20100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
3 PNG files occupy 0.06MB with 0.03MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/menu-icon.png3.75KB0.93KB▼ 75.20%
screenshot-1.png27.20KB16.23KB▼ 40.34%
screenshot-2.png32.61KB19.51KB▼ 40.16%