diff --git a/Userland/passwd.cpp b/Userland/passwd.cpp index 5e9ed17e4b..3ec586adc0 100644 --- a/Userland/passwd.cpp +++ b/Userland/passwd.cpp @@ -108,7 +108,7 @@ int main(int argc, char** argv) } // target_account is the account we are changing the password of. - auto target_account = account_or_error.value(); + auto& target_account = account_or_error.value(); if (current_uid != 0 && current_uid != target_account.uid()) { fprintf(stderr, "You can't modify passwd for %s\n", username); diff --git a/Userland/su.cpp b/Userland/su.cpp index a91e67518b..070070bf04 100644 --- a/Userland/su.cpp +++ b/Userland/su.cpp @@ -68,7 +68,7 @@ int main(int argc, char** argv) return 1; } - Core::Account account = account_or_error.value(); + const auto& account = account_or_error.value(); if (getuid() != 0 && account.has_password()) { auto password = Core::get_password();