Skip to content

Commit

Permalink
Include GraphQL Errors on warn (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
PabloSzx authored Feb 16, 2023
1 parent fbf0b0c commit bd42e6e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/rude-plants-marry.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@soundxyz/response-cache": patch
---

Include GraphQL Errors on "Failed to cache due to errors"
2 changes: 1 addition & 1 deletion src/plugin/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ export const defaultBuildResponseCacheKey: BuildResponseCacheKeyFunction = (para
export const defaultShouldCacheResult: ShouldCacheResultFunction = (params): Boolean => {
if (params.result.errors) {
// eslint-disable-next-line no-console
console.warn("[useResponseCache] Failed to cache due to errors");
console.warn("[useResponseCache] Failed to cache due to errors", params.result.errors);
return false;
}

Expand Down

0 comments on commit bd42e6e

Please sign in to comment.