UBER-914: map to mixin after findAll (#3745)

Signed-off-by: Vyacheslav Tumanov <me@slavatumanov.me>
This commit is contained in:
Vyacheslav Tumanov 2023-09-27 13:39:28 +05:00 committed by GitHub
parent 78e2393af2
commit 2f1a277e9f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -76,7 +76,7 @@ export async function getEmployee (employee: Ref<Employee>, control: TriggerCont
{ limit: 1 }
)
)[0]
return account
return account !== undefined ? control.hierarchy.as(account, contact.mixin.Employee) : undefined
}
/**