diff --git a/db/redis/client.go b/db/redis/client.go index 559890a..8683ddc 100644 --- a/db/redis/client.go +++ b/db/redis/client.go @@ -49,14 +49,14 @@ func (c *Client) Set(ctx context.Context, key string, value interface{}, expirat return c.cli.Set(ctx, key, value, expiration) } -func (c *Client) HSet(ctx context.Context, key string, values ...interface{}) *redis.IntCmd { - return c.cli.HSet(ctx, key, values) -} - func (c *Client) Get(ctx context.Context, key string) *redis.StringCmd { return c.cli.Get(ctx, key) } +func (c *Client) HSet(ctx context.Context, key string, values ...interface{}) *redis.IntCmd { + return c.cli.HSet(ctx, key, values...) +} + func (c *Client) HGet(ctx context.Context, key, field string) *redis.StringCmd { return c.cli.HGet(ctx, key, field) } @@ -65,6 +65,10 @@ func (c *Client) HGetAll(ctx context.Context, key string) *redis.MapStringString return c.cli.HGetAll(ctx, key) } +func (c *Client) HDel(ctx context.Context, key string, fields ...string) *redis.IntCmd { + return c.cli.HDel(ctx, key, fields...) +} + func (c *Client) Pipeline() redis.Pipeliner { return c.cli.Pipeline() }