401
This commit is contained in:
parent
7bcf3984e2
commit
b443eebec3
1 changed files with 1 additions and 5 deletions
|
@ -15,7 +15,6 @@ import {
|
|||
getCastThumbnailURL,
|
||||
getEndpoint,
|
||||
} from "@ente/shared/network/api";
|
||||
import { HttpStatusCode } from "axios";
|
||||
import type { CastData } from "services/cast-data";
|
||||
import { detectMediaMIMEType } from "services/detect-type";
|
||||
import {
|
||||
|
@ -97,10 +96,7 @@ export const renderableImageURLs = async function* (castData: CastData) {
|
|||
urls.push(await createRenderableURL(castToken, file));
|
||||
haveEligibleFiles = true;
|
||||
} catch (e) {
|
||||
if (
|
||||
e instanceof ApiError &&
|
||||
e.httpStatusCode == HttpStatusCode.Unauthorized
|
||||
) {
|
||||
if (e instanceof ApiError && e.httpStatusCode == 401) {
|
||||
// The token has expired. Rethrow the error, which will
|
||||
// bring us back to the pairing page.
|
||||
throw e;
|
||||
|
|
Loading…
Add table
Reference in a new issue