Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 1a28d0c

Browse filesBrowse files
committed
Allow errors from redis delete calls to be returned
Extension to revel#603
1 parent 56ad5d2 commit 1a28d0c
Copy full SHA for 1a28d0c

File tree

Expand file treeCollapse file tree

1 file changed

+2
-2
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-2
lines changed

‎cache/redis.go

Copy file name to clipboardExpand all lines: cache/redis.go
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,8 @@ func (c RedisCache) Delete(key string) error {
127127
conn := c.pool.Get()
128128
defer conn.Close()
129129
existed, err := redis.Bool(conn.Do("DEL", key))
130-
if !existed {
131-
return ErrCacheMiss
130+
if err == nil && !existed {
131+
err = ErrCacheMiss
132132
}
133133
return err
134134
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.