aboutsummaryrefslogtreecommitdiff
path: root/src/guff/api-methods.cr
diff options
context:
space:
mode:
Diffstat (limited to 'src/guff/api-methods.cr')
-rw-r--r--src/guff/api-methods.cr16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/guff/api-methods.cr b/src/guff/api-methods.cr
index c29b324..14c71c2 100644
--- a/src/guff/api-methods.cr
+++ b/src/guff/api-methods.cr
@@ -25,7 +25,8 @@ module Guff
"tags": {
text: "Comma-separated list of tags (union)",
- type: :tag_list,
+ # type: :tag_list,
+ type: :json,
required: false,
default: "",
},
@@ -68,7 +69,8 @@ module Guff
"tags": {
text: "Post tags.",
- type: :tag_list,
+ # type: :tag_list,
+ type: :json,
required: false,
default: "",
},
@@ -88,7 +90,8 @@ module Guff
"tags": {
text: "Post tags.",
- type: :tag_list,
+ # type: :tag_list,
+ type: :json,
required: false,
default: "",
},
@@ -171,7 +174,8 @@ module Guff
args: {
"tags": {
text: "Tags to remove.",
- type: :tag_list,
+ # type: :tag_list,
+ type: :json,
required: false,
default: "",
},
@@ -268,10 +272,10 @@ module Guff
slug: /^[a-z0-9\.-]+$/,
int: /^\d+$/,
int_list: /^\d+(?:,\d+)*$/,
- tag_list: /^(?:[a-z0-9_\/ -]+(?:,[a-z0-9_\/ -]+)*|)$/,
sort: /^[a-z0-9_]+,(?:asc|desc)$/,
- # FIXME: lock this down more
+ # FIXME: lock these down more
+ json: /.*/,
path: /^[^\/].*[^\/]$/,
}