Update GetIntPointerOpts function to return NOT_FOUND when none of the filters pass

This commit is contained in:
ionutboangiu
2022-03-08 18:17:00 +02:00
committed by Dan Christian Bogos
parent af4eb71761
commit 004a91a6a6

View File

@@ -262,7 +262,7 @@ func GetIntPointerOpts(ctx *context.Context, tnt string, ev *utils.CGREvent, fS
return opt.Value, nil
}
}
return nil, nil // return NOT_FOUND if there are no options and none of the filters pass
return nil, utils.ErrNotFound // return NOT_FOUND if there are no options and none of the filters pass
}
// GetDurationPointerOptsFromMultipleMaps checks the specified option names in order among the keys in APIOpts, then in startOpts, returning the first value it finds as *time.Duration,