Skip to content
This repository has been archived by the owner on Oct 15, 2024. It is now read-only.

Added panic if connection got error #4

Merged
merged 1 commit into from
Dec 16, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion gcurtain.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ type GCurtain struct {
}

func (g *GCurtain) Init(uri string) {
uriParsed, _ := redis.ParseURL(uri)
uriParsed, err := redis.ParseURL(uri)

if err != nil {
panic(err)
}

g.redisClient = redis.NewClient(uriParsed)
}

Expand Down