Skip to content

Commit

Permalink
💡 [patch] Fix erroneous type (#94)
Browse files Browse the repository at this point in the history
Deserialization happens on redis values, which are strings. With this
PR, I'm simply adjusting the type to better reflect the reality.
  • Loading branch information
christianblais authored Aug 19, 2024
1 parent 9f06eb5 commit 3a2bb05
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/RedisCache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ export class RedisCache extends CacheInstance {
* > If the key is missing, reply will be null.
*
*/
public static deserializeValue(value: CachableValue): CachableValue {
public static deserializeValue(value: string | null): CachableValue {

if (value === null) {
// null means that the key was not present, which we interpret as undefined.
Expand Down

0 comments on commit 3a2bb05

Please sign in to comment.