mirror of
https://github.com/anyproto/any-sync.git
synced 2025-06-08 05:57:03 +09:00
GO-3921: fix value check
Signed-off-by: AnastasiaShemyakinskaya <shem98a@mail.ru>
This commit is contained in:
parent
9ca41da8b6
commit
e4400aadae
1 changed files with 1 additions and 1 deletions
|
@ -168,7 +168,7 @@ func (c *oCache) load(ctx context.Context, id string, e *entry) {
|
||||||
|
|
||||||
c.mu.Lock()
|
c.mu.Lock()
|
||||||
defer c.mu.Unlock()
|
defer c.mu.Unlock()
|
||||||
if value == nil {
|
if value == nil && err == nil {
|
||||||
err = fmt.Errorf("loaded value is nil, id: %s", id)
|
err = fmt.Errorf("loaded value is nil, id: %s", id)
|
||||||
}
|
}
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue