fix: initial value checker

This commit is contained in:
Linventif 2024-06-28 19:17:45 +00:00
parent b708569ff6
commit 3ecba4cda8

View File

@ -447,9 +447,7 @@ function gmInte.openConfigMenu(data)
end end
end end
local isLastID = 0 local isLastID = 0
local initialValue = value
input.OnChange = function(self) input.OnChange = function(self)
if (self:GetValue() == initialValue) then return end
if (actualConfig.resetIfEmpty && self:GetValue() == "" && actualConfig.defaultValue) then if (actualConfig.resetIfEmpty && self:GetValue() == "" && actualConfig.defaultValue) then
self:SetText(actualConfig.defaultValue) self:SetText(actualConfig.defaultValue)
return return