From ad1622c2aa6fc2d9f36ee8ffe8f89fd880bde0ee Mon Sep 17 00:00:00 2001
From: rswindell <>
Date: Sun, 12 Apr 2020 07:27:24 +0000
Subject: [PATCH] Restore the previous behavior of File.iniGetObject(null),
 even though not documented (it says if the section is *undefined*, the root
 section is read)

---
 src/sbbs3/js_file.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/sbbs3/js_file.c b/src/sbbs3/js_file.c
index b750189449..4815b6de3a 100644
--- a/src/sbbs3/js_file.c
+++ b/src/sbbs3/js_file.c
@@ -1209,7 +1209,7 @@ js_iniGetObject(JSContext *cx, uintN argc, jsval *arglist)
 		return(JS_TRUE);
 
 	uintN argn = 0;
-	if(argc > argn && !JSVAL_IS_BOOLEAN(argv[argn])) {
+	if(argc > argn && !JSVAL_IS_BOOLEAN(argv[argn]) && !JSVAL_NULL_OR_VOID(argv[argn])) {
 		JSVALUE_TO_MSTRING(cx, argv[argn], section, NULL);
 		HANDLE_PENDING(cx, section);
 		argn++;
-- 
GitLab