mirror of
https://github.com/EchoVault/SugarDB.git
synced 2025-09-26 20:11:15 +08:00
fix: Updating hash value would sometimes replace the entire hash
https://github.com/EchoVault/SugarDB/issues/179
This commit is contained in:
@@ -79,7 +79,7 @@ func handleHSET(params internal.HandlerFuncParams) ([]byte, error) {
|
||||
// Handle HSET
|
||||
for field, value := range hash {
|
||||
if entries[field].Value == nil {
|
||||
entries[field] = HashValue{Value: value}
|
||||
entries[field] = value
|
||||
}
|
||||
}
|
||||
count = len(entries)
|
||||
|
Reference in New Issue
Block a user