Skip to content

Commit

Permalink
Bug fix: Redis response cache type mismatch (#3181)
Browse files Browse the repository at this point in the history
* Type fix

* changeset
  • Loading branch information
gilgardosh authored Feb 7, 2024
1 parent a852e34 commit 35387c0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/moody-crabs-train.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@graphql-yoga/plugin-response-cache': patch
---

Type fix to match `@envelop/response-cache-redis`
4 changes: 3 additions & 1 deletion packages/plugins/response-cache/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,9 @@ export interface ResponseCachePluginExtensions {
export interface Cache extends EnvelopCache {
get(
key: string,
): Promise<ExecutionResult<Record<string, unknown>, ResponseCachePluginExtensions> | undefined>;
): PromiseOrValue<
ExecutionResult<Record<string, unknown>, ResponseCachePluginExtensions> | undefined
>;
}

export function useResponseCache(options: UseResponseCacheParameter): Plugin {
Expand Down

0 comments on commit 35387c0

Please sign in to comment.