chore(test): fix deprecated call or syntax

This commit is contained in:
Edouard Vanbelle
2026-06-11 03:06:47 +02:00
parent 595273277b
commit 140cbb440e
9 changed files with 24 additions and 24 deletions
+2 -2
View File
@@ -49,8 +49,8 @@ rest_delete() { curl -s -o /dev/null -w "%{http_code}" -X DELETE -H "Authorizati
purge_from_trash() {
local name="$1"
local tid
tid=$(rest_get "/api/trash" \
| jq -r --arg n "$name" 'first(.[] | select(.name == $n) | .id) // empty')
tid=$(rest_get "/api/trash/resources" \
| jq -r --arg n "$name" 'first(.items[] | select(.resource.name == $n) | .resource.id) // empty')
[[ -n "$tid" ]] && rest_delete "/api/trash/$tid" > /dev/null || true
}