From 18b29b2ffe67c6f45c84d0c6db427ab46f4b6c6d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Deuc=D0=B5?= <shurd@sasktel.net>
Date: Thu, 2 Jan 2025 11:36:03 -0500
Subject: [PATCH] Use the new console.term_supports() method.

While it's only been around for about 18 years, I'll assume that
anyone updating the exec directory has updated Synchronet as well.
---
 exec/load/lightbar.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/exec/load/lightbar.js b/exec/load/lightbar.js
index d3a2ec154a..d8c1b0f944 100644
--- a/exec/load/lightbar.js
+++ b/exec/load/lightbar.js
@@ -362,11 +362,11 @@ Lightbar.prototype.draw = function(current)
 
 	if(current!=undefined)
 		this.current=current;
-	if(!(user.settings & USER_ANSI)) {
+	if(!console.term_supports(USER_ANSI)) {
 		alert("ANSI not supported!");
 		return;
 	}
-	if(!(user.settings & USER_COLOR)) {
+	if(!console.term_supports(USER_COLOR)) {
 		alert("Colour not supported!");
 		return;
 	}
-- 
GitLab