Skip to content

Commit

Permalink
fix: coerce _rev to string and make it optional
Browse files Browse the repository at this point in the history
  • Loading branch information
velut committed Apr 20, 2024
1 parent ed6785f commit 8038b6f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/get-packument.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,6 @@ export const Packument = PackageJson.pick({
/** Package name used as the ID in CouchDB. */
_id: z.string(),

/** Revision ID of the document in CouchDB. */
_rev: z.number(),

/** Package name. */
name: z.string(),

Expand All @@ -53,6 +50,9 @@ export const Packument = PackageJson.pick({
*/
versions: z.record(PackageManifest),

/** Revision ID of the document in CouchDB. */
_rev: z.coerce.string().optional(),

/** Mapping of npm usernames of users who starred the package to `true`. */
users: z.record(z.boolean()).optional(),

Expand Down

0 comments on commit 8038b6f

Please sign in to comment.