Members
(static, constant) STATUS_AVAILABLE
- Default Value
- available
(static, constant) STATUS_UNAVAILABLE
- Default Value
- unavailable
(static, constant) STATUS_UNKNOWN
Methods
(static) recordSubtitleProviderStatus(res) → {string}
recordSubtitleProviderStatus: Store a reply's answer on m.global.server.
An unknown answer is NOT stored, so a failed check is retried by the next consumer instead of being remembered for the rest of the session.
| Name | Type | Description |
|---|---|---|
res | object | fetchAsync result { ok, json } |
the status the reply gave, stored or not
- Type:
- string
(static) shouldOfferSubtitleSearch(status) → {boolean}
shouldOfferSubtitleSearch: Whether to offer Manage Subtitles once the provider check has settled.
This capability FAILS OPEN: only a definite "unavailable" hides the button, and an unknown result here (the check failed) offers it. Safe for this feature specifically — a search without a provider returns an empty success, the panel says so and points at provider setup, and nothing is changed on the server. A transport error is not evidence the plugin is missing, so hiding a working feature on a network blip would be the worse outcome. Not a default for other capabilities; see the header.
| Name | Type | Description |
|---|---|---|
status | string | the status the check produced |
- Type:
- boolean
(static) subtitleProviderStatusFrom(res) → {string}
subtitleProviderStatusFrom: What a /Libraries/AvailableOptions reply says about subtitle providers.
SubtitleFetchers lists every installed subtitle provider plugin by name. It cannot tell whether a provider has CREDENTIALS — an installed but unconfigured provider counts as available, and the panel's empty-state message covers that.
the reply does not answer the question (non-ok, malformed)
| Name | Type | Description |
|---|---|---|
res | object | fetchAsync result { ok, json } |
STATUS_AVAILABLE / STATUS_UNAVAILABLE, or STATUS_UNKNOWN when
- Type:
- string