Skip to content

Commit

Permalink
fix: useCommit doesn't always expect flags (#3570)
Browse files Browse the repository at this point in the history
  • Loading branch information
JerrySentry authored Dec 11, 2024
1 parent c729790 commit 606eb5d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ const FlagError = () => (
interface RenderErrorProps {
errors: (UploadErrorObject | null)[]
state: (typeof UploadStateEnum)[keyof typeof UploadStateEnum]
flags: string[] | null
flags: string[] | null | undefined
}

const RenderError = ({ errors, state, flags }: RenderErrorProps) => {
Expand Down
2 changes: 1 addition & 1 deletion src/services/commit/useCommit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ const UploadSchema = z.object({
provider: z.string().nullable(),
createdAt: z.string(),
updatedAt: z.string(),
flags: z.array(z.string()).nullable(),
flags: z.array(z.string()).nullish(),
jobCode: z.string().nullable(),
downloadUrl: z.string(),
ciUrl: z.string().nullable(),
Expand Down
2 changes: 1 addition & 1 deletion src/shared/utils/extractUploads.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export interface Upload {
provider: string | null
createdAt: string
updatedAt: string
flags: string[] | null
flags?: string[] | null
jobCode: string | null
downloadUrl: string
ciUrl: string | null
Expand Down

0 comments on commit 606eb5d

Please sign in to comment.