mirror of
https://git.sr.ht/~cadence/bibliogram
synced 2026-03-01 18:31:35 +00:00
Slightly improve blocked detection
This commit is contained in:
parent
ca1c965021
commit
8c8808e1dc
3 changed files with 12 additions and 3 deletions
|
|
@ -16,6 +16,12 @@ class AssistantSwitcher {
|
|||
return this.assistants.filter(assistant => assistant.available()).sort((a, b) => (a.lastRequest - b.lastRequest))
|
||||
}
|
||||
|
||||
displaySomeUnblocked() {
|
||||
return this.assistants.some(assistant =>
|
||||
[constants.symbols.assistant_statuses.NONE, constants.symbols.assistant_statuses.OK].includes(assistant.lastRequestStatus)
|
||||
)
|
||||
}
|
||||
|
||||
requestUser(username) {
|
||||
return new Promise(async (resolve, reject) => {
|
||||
const assistants = this.getAvailableAssistants()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue