Skip to content

Commit

Permalink
Merge pull request #2 from BolajiOlajide/bo/fix-zod-error
Browse files Browse the repository at this point in the history
fix zod error
  • Loading branch information
lilpolymath authored Jun 20, 2024
2 parents 99c711a + f563df6 commit e4f6a32
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@ export class NowPlaying {
this.provider = provider

this.parseArgs(args)
this.streamerArgs = args.streamerArgs
this.storageKind = args.storageKind || StorageKinds.INMEMORY
this.useCache = args.useCache || true
this.cacheDuration = args.cacheDuration || 60000;

// this is whatever storage mechanic the user selects
this.storer = this.getStorer(this.storageKind)
this.streamer = this.getStreamer()
this.streamerArgs = args.streamerArgs
}

private parseArgs(args: unknown): void {
Expand Down
2 changes: 1 addition & 1 deletion src/schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,6 @@ export const SpotifyProviderArgsSchema = BaseNowPlayingArgsSchema.extend({
export type SpotifyProviderArgs = z.infer<typeof SpotifyProviderArgsSchema>;

export const NoopProviderArgsSchema = BaseNowPlayingArgsSchema.extend({
streamerArgs: z.unknown(),
streamerArgs: z.never(),
});
export type NoopProviderArgs = z.infer<typeof NoopProviderArgsSchema>;

0 comments on commit e4f6a32

Please sign in to comment.