Merge pull request #664 from happymimimix/master

Blank password fix (2nd time)
This commit is contained in:
IgorTimofeev 2025-02-14 17:55:03 +03:00 committed by GitHub
commit 0f83657cc8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -352,7 +352,7 @@ end
local function checkUserInputs()
local nameEmpty = #usernameInput.text == 0
local nameVaild = usernameInput.text:match("^%w[%w%s_]+$")
local passValid = withoutPasswordSwitchAndLabel.switch.state or #passwordInput.text == 0 or #passwordSubmitInput.text == 0 or passwordInput.text == passwordSubmitInput.text
local passValid = withoutPasswordSwitchAndLabel.switch.state or (#passwordInput.text > 0 and #passwordSubmitInput.text > 0 and passwordInput.text == passwordSubmitInput.text)
if (nameEmpty or nameVaild) and passValid then
usernamePasswordText.hidden = true
@ -418,7 +418,7 @@ end)
-- Filesystem selection stage
addStage(function()
prevButton.disabled = false
nextButton.disabled = false
nextButton.disabled = true
layout:addChild(GUI.object(1, 1, 1, 1))
addTitle(0x696969, localization.select)