fix: Clear stale media unavailable errors when a camera recovers (#2627)
- Closes: #2576
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import type { IssueTriggerContext } from 'issue';
|
||||
import type { IssueResolveContext, IssueTriggerContext } from 'issue';
|
||||
|
||||
import type { ConditionStateChange } from '../../condition-trigger/conditions/types';
|
||||
import { contentsChanged, ignoreFunctionIdentity } from '../../utils/basic';
|
||||
@@ -11,6 +11,7 @@ import type {
|
||||
IssueKey,
|
||||
IssuePresence,
|
||||
IssueReadOnlyState,
|
||||
IssueResolveContextKey,
|
||||
IssueTriggerContextKey,
|
||||
} from './types';
|
||||
|
||||
@@ -71,6 +72,16 @@ export class IssueManager {
|
||||
this.evaluate();
|
||||
}
|
||||
|
||||
// Called by components that observe a problem recovering directly (e.g. a
|
||||
// stream that is proven to be delivering media again).
|
||||
public resolve<K extends IssueResolveContextKey>(
|
||||
key: K,
|
||||
context: IssueResolveContext[K],
|
||||
): void {
|
||||
this._stateManager.resolve(key, context);
|
||||
this.evaluate();
|
||||
}
|
||||
|
||||
// Evaluate all dynamic issues against current state, re-render the card if
|
||||
// the issue presence changed, and schedule retries.
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user