From a47786a246342f0b4016d083fc109f4b601ddbc1 Mon Sep 17 00:00:00 2001 From: "sojung.kim" Date: Thu, 3 Oct 2024 20:18:54 +0900 Subject: [PATCH] feat: add encoding.BinaryUnmarshaler in Scan --- internal/hscan/structmap.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/internal/hscan/structmap.go b/internal/hscan/structmap.go index 1a560e4a..408ce0e4 100644 --- a/internal/hscan/structmap.go +++ b/internal/hscan/structmap.go @@ -109,6 +109,8 @@ func (s StructValue) Scan(key string, value string) error { return scan.ScanRedis(value) case encoding.TextUnmarshaler: return scan.UnmarshalText(util.StringToBytes(value)) + case encoding.BinaryUnmarshaler: + return scan.UnmarshalBinary(util.StringToBytes(value)) } }