Merge pull request #2 from true-og/agent/skip-disabled-virtual-display-check

Skip virtual display self-test when displays are disabled
This commit was merged in pull request #2.
This commit is contained in:
NotAlexNoyle authored and GitHub committed 2026-07-22 17:06:07 -04:00
commit 4a671fbe05
1 file changed
+12
@@ -510,6 +510,18 @@ public final class EnvironmentChecker {
@EnvCheckEntry(name = "Virtual DisplayItem Support Test", priority = 7, stage = EnvCheckEntry.Stage.AFTER_ON_ENABLE)
public ResultContainer virtualDisplayWorkingTest() {
if (!plugin.isDisplayEnabled()) {
return new ResultContainer(CheckResult.PASSED, "The display are disabled.");
}
if (AbstractDisplayItem.getNowUsing() != DisplayType.VIRTUALITEM) {
return new ResultContainer(CheckResult.PASSED, "The display type is not virtual item.");
}
if (plugin.getVirtualDisplayItemManager() == null) {
AbstractDisplayItem.setVirtualDisplayDoesntWork(true);