Skip to content
This repository was archived by the owner on Sep 9, 2025. It is now read-only.

Commit bda43be

Browse files
committed
Fixed optional property types
1 parent 478aeb1 commit bda43be

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

src/backend/move.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -65,16 +65,16 @@ export function move(
6565
return { response: { errors }, status: "success" };
6666
} catch (e: unknown) {
6767
return {
68-
detail:
69-
typeof e === "object" &&
68+
...(typeof e === "object" &&
7069
e !== null &&
7170
"message" in e &&
72-
typeof e.message === "string"
73-
? e.message +
71+
typeof e.message === "string" && {
72+
detail:
73+
e.message +
7474
("stack" in e && typeof e.stack === "string"
7575
? `\n\nStack trace:\n${e.stack}`
76-
: "")
77-
: undefined,
76+
: ""),
77+
}),
7878
status: "error",
7979
type: "DriveAPIError",
8080
};

src/backend/utils/SafeDriveService/SafeCommentsCollection.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export interface SafeComment {
1818

1919
export interface SafeCommentList<F extends DeepKeyof<SafeComment>> {
2020
comments: Array<DeepPick<SafeComment, F>>;
21-
nextPageToken?: string | undefined;
21+
nextPageToken?: string;
2222
}
2323

2424
interface SafeReply {

src/backend/utils/SafeDriveService/SafeFilesCollection.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ const safeFileKeys: DeepKeyof<SafeFile> = {
3939

4040
export interface SafeFileList<F extends DeepKeyof<SafeFile>> {
4141
files: Array<DeepPick<SafeFile, F>>;
42-
nextPageToken?: string | undefined;
42+
nextPageToken?: string;
4343
}
4444
interface GetArg {
4545
alt?: string;

0 commit comments

Comments
 (0)