mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2025-07-21 02:55:45 +00:00
common/uuid: Add validity checking functions to interface
Given we have a function to invalidate, we should also have ones to query the validity. Also makes the code more straightforward to read.
This commit is contained in:
parent
b7d572c780
commit
e37bea609c
4 changed files with 14 additions and 7 deletions
|
@ -929,8 +929,7 @@ void Module::Interface::TrySelectUserWithoutInteraction(Kernel::HLERequestContex
|
|||
}
|
||||
|
||||
const auto user_list = profile_manager->GetAllUsers();
|
||||
if (std::all_of(user_list.begin(), user_list.end(),
|
||||
[](const auto& user) { return user.uuid == Common::INVALID_UUID; })) {
|
||||
if (std::ranges::all_of(user_list, [](const auto& user) { return user.IsInvalid(); })) {
|
||||
rb.Push(ResultUnknown); // TODO(ogniK): Find the correct error code
|
||||
rb.PushRaw<u128>(Common::INVALID_UUID);
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue