1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 04:27:45 +00:00

LibCore+passwd+usermod: Make Core::Account::sync() return ErrorOr<void>

This commit is contained in:
Andreas Kling 2021-12-16 21:41:57 +01:00
parent ead9c36c92
commit b38f8902d2
4 changed files with 25 additions and 61 deletions

View file

@ -92,11 +92,8 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
TRY(Core::System::pledge("stdio wpath rpath cpath fattr"));
if (!target_account.sync()) {
perror("Core::Account::Sync");
} else {
outln("Password for user {} successfully updated.", target_account.username());
}
TRY(target_account.sync());
outln("Password for user {} successfully updated.", target_account.username());
return 0;
}