73% intrackt-vendors

Code Review | Intrackt Vendors

WordPress plugin Intrackt Vendors scored 73% from 54 tests.

About plugin

  • Plugin page: intrackt-vendors
  • Plugin version: 1.0.1
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3.2-5.8
  • WordPress version: 5.9.2
  • First release: Nov 16, 2020
  • Latest release: Jul 15, 2021
  • Number of updates: 5
  • Update frequency: every 48.8 days
  • Top authors: intrackt (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 199 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.37MB] [CPU: ▼295.58ms] Passed 4 tests

An overview of server-side resources used by Intrackt Vendors
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.64 ▲0.1356.08 ▲6.47
Dashboard /wp-admin3.48 ▲0.0734.41 ▲2.28
Posts /wp-admin/edit.php2.05 ▼1.594.54 ▼32.44
Add New Post /wp-admin/post-new.php6.94 ▼0.0295.17 ▼1,152.02
Media Library /wp-admin/upload.php3.36 ▲0.0724.08 ▼0.13
Vendors /wp-admin/admin.php?page=intracktvendors-main3.4028.36
--Log /wp-admin/admin.php?page=intracktvendors-log3.3329.15
Intrackt /wp-admin/admin.php?page=intrackt-common3.3322.03

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 8 new files
Database: 1 new table, 2 new options
New tables
wp_intrackt_log
New WordPress options
intrackt_vendors_next_sku_id
intrackt_vendors

Browser metrics Passed 4 tests

An overview of browser requirements for Intrackt Vendors
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,801 ▲4715.77 ▲0.035.78 ▼0.792.27 ▼0.89
Dashboard /wp-admin2,930 ▲726.08 ▼0.08122.52 ▼9.11154.72 ▼3.92
Posts /wp-admin/edit.php2,725 ▲313.24 ▲0.0064.88 ▲2.23138.10 ▲3.65
Add New Post /wp-admin/post-new.php1,643 ▼5520.74 ▼0.98408.77 ▼40.10158.33 ▼6.27
Media Library /wp-admin/upload.php1,736 ▲385.49 ▼0.05140.27 ▼3.03184.69 ▼7.84
Vendors /wp-admin/admin.php?page=intracktvendors-main2,8508.63154.95117.51
--Log /wp-admin/admin.php?page=intracktvendors-log9942.4154.6099.84
Intrackt /wp-admin/admin.php?page=intrackt-common1,0262.3752.60100.55

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • The uninstall procedure failed, leaving 1 table in the database
    • wp_intrackt_log
  • The uninstall procedure has failed, leaving 2 options in the database
    • intrackt_vendors
    • intrackt_vendors_next_sku_id

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

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
Please fix the following items
  • 13× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Warning
      Use of undefined constant INTRACKT_VENDORS_PLUGIN_DIR - assumed 'INTRACKT_VENDORS_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-Manager.php on line 7
    • > PHP Fatal error
      require_once(): Failed opening required 'INTRACKT_VENDORS_PLUGIN_DIRclass.Intrackt-Vendors-PageMain.php' (include_path='.:/usr/share/php') in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-Manager.php on line 7
    • > PHP Fatal error
      require_once(): Failed opening required 'INTRACKT_VENDORS_PLUGIN_DIRclass.Intrackt-Vendors-PageLog.php' (include_path='.:/usr/share/php') in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-Common.php on line 7
    • > PHP Warning
      require_once(INTRACKT_VENDORS_PLUGIN_DIRclass.Intrackt-Vendors-PageLog.php): failed to open stream: No such file or directory in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-Common.php on line 7
    • > PHP Fatal error
      require_once(): Failed opening required 'INTRACKT_VENDORS_PLUGIN_DIRclass.Intrackt-Vendors-PageLog.php' (include_path='.:/usr/share/php') in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-PageMain.php on line 7
    • > PHP Warning
      require_once(INTRACKT_VENDORS_PLUGIN_DIRclass.Intrackt-Vendors-PageMain.php): failed to open stream: No such file or directory in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-Manager.php on line 7
    • > PHP Warning
      Use of undefined constant INTRACKT_VENDORS_PLUGIN_DIR - assumed 'INTRACKT_VENDORS_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-Common.php on line 7
    • > PHP Fatal error
      require_once(): Failed opening required 'INTRACKT_VENDORS_PLUGIN_DIRclass.Intrackt-Vendors-PageLog.php' (include_path='.:/usr/share/php') in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-Actions.php on line 7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/intrackt-vendors/Intrackt-Vendors.php:28
    • > PHP Warning
      Use of undefined constant INTRACKT_VENDORS_PLUGIN_DIR - assumed 'INTRACKT_VENDORS_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/intrackt-vendors/class.Intrackt-Vendors-Actions.php on line 7

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

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Tags: Please reduce the number of tags, currently 11 tag instead of maximum 10
The official readme.txt is a good inspiration

intrackt-vendors/Intrackt-Vendors.php 85% from 13 tests

The main file in "Intrackt Vendors" v. 1.0.1 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 ("intrackt-vendors.php" instead of "Intrackt-Vendors.php")
  • Text Domain: The text domain follows the same naming rules as the plugin slug: lowercase characters and dashes

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
There were no executable files found in this plugin2,411 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP69412,0302,411

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity58.60
▷ Minimum class complexity6.00
▷ Maximum class complexity132.00
Average method complexity4.31
▷ Minimum method complexity1.00
▷ Maximum method complexity34.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods87
▷ Static methods87100.00%
▷ Public methods8091.95%
▷ Protected methods00.00%
▷ Private methods78.05%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin