add back else clause
Add back else clause after realizing the error check doesn't return after logging.
This commit is contained in:
parent
30fc088cec
commit
fcf01a6039
7
read.go
7
read.go
@ -171,11 +171,12 @@ func updateTimelineCache(tl *localTimeline, reset bool) {
|
|||||||
postsInterfaces, err := tl.m.Get()
|
postsInterfaces, err := tl.m.Get()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Error("[READ] Unable to cache posts: %v", err)
|
log.Error("[READ] Unable to cache posts: %v", err)
|
||||||
|
} else {
|
||||||
|
castPosts := postsInterfaces.([]PublicPost)
|
||||||
|
tl.posts = &castPosts
|
||||||
}
|
}
|
||||||
|
|
||||||
castPosts := postsInterfaces.([]PublicPost)
|
|
||||||
tl.posts = &castPosts
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func showLocalTimeline(app *App, w http.ResponseWriter, r *http.Request, page int, author, tag string) error {
|
func showLocalTimeline(app *App, w http.ResponseWriter, r *http.Request, page int, author, tag string) error {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user