minor fix: fix wrong check of annotation_ids (#23164)
This commit is contained in:
parent
bbdeb15501
commit
070379a900
1 changed files with 2 additions and 1 deletions
|
|
@ -137,7 +137,8 @@ class AnnotationListApi(Resource):
|
|||
|
||||
# If annotation_ids are provided, handle batch deletion
|
||||
if annotation_ids:
|
||||
if not annotation_ids:
|
||||
# Check if any annotation_ids contain empty strings or invalid values
|
||||
if not all(annotation_id.strip() for annotation_id in annotation_ids if annotation_id):
|
||||
return {
|
||||
"code": "bad_request",
|
||||
"message": "annotation_ids are required if the parameter is provided.",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue