MCPcopy Create free account
hub / github.com/aiprodcoder/MIXAPI / RecordExist

Function RecordExist

model/utils.go:99–107  ·  view source on GitHub ↗
(err error)

Source from the content-addressed store, hash-verified

97}
98
99func RecordExist(err error) (bool, error) {
100 if err == nil {
101 return true, nil
102 }
103 if errors.Is(err, gorm.ErrRecordNotFound) {
104 return false, nil
105 }
106 return false, err
107}
108
109func shouldUpdateRedis(fromDB bool, err error) bool {
110 return common.RedisEnabled && fromDB && err == nil

Callers 2

GetByOnlyTaskIdFunction · 0.85
GetByTaskIdFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected