78% context-term-tidier

Code Review | Context Term Tidier

WordPress plugin Context Term Tidier scored78%from 54 tests.

About plugin

  • Plugin page: context-term-tidier
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1.0-5.2
  • WordPress version: 6.3.1
  • First release: Oct 13, 2019
  • Latest release: Oct 13, 2019
  • Number of updates: 2
  • Update frequency: every 1.0 days
  • Top authors: parakeet (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /452 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.07MB] [CPU: ▼7.95ms] Passed 4 tests

A check of server-side resources used by Context Term Tidier
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0739.55 ▼2.24
Dashboard /wp-admin3.39 ▲0.0444.10 ▼13.96
Posts /wp-admin/edit.php3.50 ▲0.1448.06 ▲4.19
Add New Post /wp-admin/post-new.php5.97 ▲0.0880.66 ▼16.08
Media Library /wp-admin/upload.php3.31 ▲0.0836.54 ▲0.49
Context Term Tidier /wp-admin/options-general.php?page=magic-terms-settings3.2629.12
Context Term Tidier /wp-admin/tools.php?page=magic-terms3.2630.11

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Context Term Tidier
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,797 ▲5114.17 ▼0.361.66 ▲0.0643.98 ▲3.33
Dashboard /wp-admin2,203 ▲265.57 ▼0.1491.44 ▲4.7637.30 ▼1.67
Posts /wp-admin/edit.php2,111 ▲82.00 ▲0.0035.69 ▲0.3832.02 ▼1.48
Add New Post /wp-admin/post-new.php1,537 ▲1122.90 ▼0.71667.94 ▼0.4072.94 ▲18.67
Media Library /wp-admin/upload.php1,408 ▲54.13 ▼0.06109.75 ▲12.8946.13 ▼0.27
Context Term Tidier /wp-admin/options-general.php?page=magic-terms-settings1,3481.9925.8527.67
Context Term Tidier /wp-admin/tools.php?page=magic-terms8571.8226.9126.00

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

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
  • 73 occurences, only the last one shown
    • > GET request to /wp-admin/tools.php?page=magic-terms
    • > Notice in wp-content/plugins/context-term-tidier/cxt-term-tidier.php+558
    Trying to access array offset on value of type bool
  • 8 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=magic-terms-settings
    • > Notice in wp-content/plugins/context-term-tidier/cxt-term-tidier.php+404
    Undefined variable: taxonomy
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/tools.php?page=magic-terms
    • > Notice in wp-content/plugins/context-term-tidier/cxt-term-tidier.php+611
    Trying to get property 'labels' of non-object
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/tools.php?page=magic-terms
    • > Notice in wp-content/plugins/context-term-tidier/cxt-term-tidier.php+611
    Trying to get property 'singular_name' of non-object

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 fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/context-term-tidier/cxt-term-tidier.php:45

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 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
3 plugin tags: taxonomies, terms, tags

context-term-tidier/cxt-term-tidier.php 92% from 13 tests

The main file in "Context Term Tidier" v. 1.0.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("context-term-tidier.php" instead of "cxt-term-tidier.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin540 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP1270206522
JavaScript15218

PHP code Passed 2 tests

Analyzing 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.17
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions21
▷ Named functions21100.00%
▷ Anonymous functions00.00%
Constants0
▷ 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
There were not PNG files found in your plugin