Skip virtual display self-test when displays are disabled #2

Merged
NotAlexNoyle merged 1 commits from agent/skip-disabled-virtual-display-check into main 2026-07-22 17:06:07 -04:00
NotAlexNoyle commented 2026-07-22 16:29:36 -04:00 (Migrated from github.com)

What changed

  • Skip the AFTER_ON_ENABLE virtual display self-test when display items are disabled.
  • Also skip it when the selected display type is not VIRTUALITEM.

Why

The earlier ON_ENABLE check already treats those configurations as valid, but the later check still expected a VirtualDisplayItemManager. Because that manager is intentionally absent when virtual displays are not active, startup logged a misleading warning:

VirtualDisplayItemManager is null, this shouldn't happen...

Impact

Servers with shop.display-items: false no longer receive the false-positive warning. Active virtual display configurations retain the existing manager and packet self-tests.

Validation

  • Compared the branch against main.
  • Exactly one file changed with 12 inserted lines and no deletions.
  • The added guards mirror the existing pre-enable checks.

This change is based solely on the existing GPL-era QuickShop-OG source. No post-license-change AGPL code was referenced or used.

## What changed - Skip the `AFTER_ON_ENABLE` virtual display self-test when display items are disabled. - Also skip it when the selected display type is not `VIRTUALITEM`. ## Why The earlier `ON_ENABLE` check already treats those configurations as valid, but the later check still expected a `VirtualDisplayItemManager`. Because that manager is intentionally absent when virtual displays are not active, startup logged a misleading warning: `VirtualDisplayItemManager is null, this shouldn't happen...` ## Impact Servers with `shop.display-items: false` no longer receive the false-positive warning. Active virtual display configurations retain the existing manager and packet self-tests. ## Validation - Compared the branch against `main`. - Exactly one file changed with 12 inserted lines and no deletions. - The added guards mirror the existing pre-enable checks. This change is based solely on the existing GPL-era QuickShop-OG source. No post-license-change AGPL code was referenced or used.
Sign in to join this conversation.