Skip to content

Commit

Permalink
Merge pull request #374 from Financial-Times/optional-vault
Browse files Browse the repository at this point in the history
Make vault options optional
  • Loading branch information
ivomurrell authored Mar 22, 2023
2 parents 1868556 + f2e9cc0 commit 9900ec6
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions lib/types/src/schema/vault.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
import { z } from 'zod'

export const VaultSchema = z.object({
team: z.string(),
app: z.string()
})
// In theory, these fields should be required as Vault won't work without them,
// but not every app that pulls in the Vault plugin actually needs to use
// Vault, e.g., an app that uses the `nodemon` plugin with the `useVault`
// option set to false.
export const VaultSchema = z
.object({
team: z.string(),
app: z.string()
})
.partial()
export type VaultOptions = z.infer<typeof VaultSchema>

export const Schema = VaultSchema

0 comments on commit 9900ec6

Please sign in to comment.