Skip to content

Commit

Permalink
Fix errors message
Browse files Browse the repository at this point in the history
Signed-off-by: dusanb94 <dusan.borovcanin@mainflux.com>
  • Loading branch information
dborovcanin committed Jul 14, 2020
1 parent c065335 commit 1dd8880
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 9 deletions.
14 changes: 8 additions & 6 deletions things/redis/channels.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,16 @@ import (

const chanPrefix = "channel"

// ErrRedisConnectChannel indicates error while adding connection in redis cache
var ErrRedisConnectChannel = errors.New("add connection to redis cache error")
var (
// ErrRedisConnectChannel indicates error while adding connection in redis cache
ErrRedisConnectChannel = errors.New("failed to add connection to redis cache")

// ErrRedisDisconnectChannel indicates error while removing connection from redis cache
var ErrRedisDisconnectChannel = errors.New("remove connection from redis cache error")
// ErrRedisDisconnectChannel indicates error while removing connection from redis cache
ErrRedisDisconnectChannel = errors.New("failed to remove connection from redis cache")

// ErrRedisRemoveChannel indicates error while removing channel from redis cache
var ErrRedisRemoveChannel = errors.New("remove channel from redis cache error")
// ErrRedisRemoveChannel indicates error while removing channel from redis cache
ErrRedisRemoveChannel = errors.New("failed to remove channel from redis cache")
)

var _ things.ChannelCache = (*channelCache)(nil)

Expand Down
6 changes: 3 additions & 3 deletions things/redis/things.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@ const (

var (
// ErrRedisThingSave indicates error while saving Thing in redis cache
ErrRedisThingSave = errors.New("saving thing in redis cache error")
ErrRedisThingSave = errors.New("failed to save thing in redis cache")

// ErrRedisThingID indicates error while geting Thing ID from redis cache
ErrRedisThingID = errors.New("get thing id from redis cache error")
ErrRedisThingID = errors.New("failed to get thing id from redis cache")

// ErrRedisThingRemove indicates error while removing Thing from redis cache
ErrRedisThingRemove = errors.New("remove thing from redis cache error")
ErrRedisThingRemove = errors.New("failed to remove thing from redis cache")
)

var _ things.ThingCache = (*thingCache)(nil)
Expand Down

0 comments on commit 1dd8880

Please sign in to comment.