ValidateTupleFilter checks if the provided filter conforms to the entity definition
(tupleFilter *base.TupleFilter)
| 49 | |
| 50 | // ValidateTupleFilter checks if the provided filter conforms to the entity definition |
| 51 | func ValidateTupleFilter(tupleFilter *base.TupleFilter) (err error) { |
| 52 | if IsTupleFilterEmpty(tupleFilter) { |
| 53 | return errors.New(base.ErrorCode_ERROR_CODE_VALIDATION.String()) |
| 54 | } |
| 55 | return nil |
| 56 | } |
| 57 | |
| 58 | // ValidateFilters checks if both provided filters, tupleFilter and attributeFilter, are empty. |
| 59 | // It returns an error if both filters are empty, as at least one filter should contain criteria for the operation to be valid. |
no test coverage detected