report type setting handler (commited in wrong branch)

This commit is contained in:
quenousimporte 2023-09-25 14:14:41 +02:00
parent a3c8d25299
commit 9bb5aa8287
1 changed files with 17 additions and 3 deletions

16
main.js
View File

@ -943,11 +943,25 @@ function editsetting(name)
{
if (settings[name])
{
settings[name] = prompt(name, settings[name]);
var value = settings[name];
var type = typeof value;
if (type != "undefined")
{
value = prompt(name, value);
if (type == "number")
{
value = parseInt(value);
}
else if (type == "boolean")
{
value = value === "true";
}
settings[name] = value;;
savesettings();
loadsettings();
}
}
}
function changesetting()
{