mirror of
https://github.com/tw93/Mole.git
synced 2026-03-23 02:35:07 +00:00
chore: auto format code
This commit is contained in:
@@ -76,7 +76,7 @@ _request_password() {
|
||||
|
||||
if [[ -z "$password" ]]; then
|
||||
unset password
|
||||
((attempts++))
|
||||
((attempts++)) || true
|
||||
if [[ $attempts -lt 3 ]]; then
|
||||
echo -e "${GRAY}${ICON_WARNING}${NC} Password cannot be empty" > "$tty_path"
|
||||
fi
|
||||
@@ -91,7 +91,7 @@ _request_password() {
|
||||
fi
|
||||
|
||||
unset password
|
||||
((attempts++))
|
||||
((attempts++)) || true
|
||||
if [[ $attempts -lt 3 ]]; then
|
||||
echo -e "${GRAY}${ICON_WARNING}${NC} Incorrect password, try again" > "$tty_path"
|
||||
fi
|
||||
@@ -166,7 +166,7 @@ request_sudo_access() {
|
||||
break
|
||||
fi
|
||||
sleep 0.1
|
||||
((elapsed++))
|
||||
((elapsed++)) || true
|
||||
done
|
||||
|
||||
# Touch ID failed/cancelled - clean up thoroughly before password input
|
||||
@@ -216,7 +216,7 @@ _start_sudo_keepalive() {
|
||||
local retry_count=0
|
||||
while true; do
|
||||
if ! sudo -n -v 2> /dev/null; then
|
||||
((retry_count++))
|
||||
((retry_count++)) || true
|
||||
if [[ $retry_count -ge 3 ]]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user