File tree Expand file tree Collapse file tree 1 file changed +11
-11
lines changed
example/formJsonPost/app/src Expand file tree Collapse file tree 1 file changed +11
-11
lines changed Original file line number Diff line number Diff line change @@ -13,17 +13,6 @@ object FormJsonPost extends cask.MainRoutes{
13
13
)
14
14
}
15
15
16
- @ cask.postJsonCached(" /json-obj-cached" )
17
- def jsonEndpointObjCached (value1 : ujson.Value , value2 : Seq [Int ], request : cask.Request ) = {
18
- ujson.Obj (
19
- " value1" -> value1,
20
- " value2" -> value2,
21
- // `postJsonCached` buffers up the body of the request in memory before parsing,
22
- // giving you access to the request body data if you want to use it yourself
23
- " body" -> request.text()
24
- )
25
- }
26
-
27
16
@ cask.postForm(" /form" )
28
17
def formEndpoint (value1 : cask.FormValue , value2 : Seq [Int ]) = {
29
18
" OK " + value1 + " " + value2
@@ -51,6 +40,17 @@ object FormJsonPost extends cask.MainRoutes{
51
40
" OK " + value1 + " " + value2 + " " + params.value + " " + segments.value
52
41
}
53
42
43
+ @ cask.postJsonCached(" /json-obj-cached" )
44
+ def jsonEndpointObjCached (value1 : ujson.Value , value2 : Seq [Int ], request : cask.Request ) = {
45
+ ujson.Obj (
46
+ " value1" -> value1,
47
+ " value2" -> value2,
48
+ // `postJsonCached` buffers up the body of the request in memory before parsing,
49
+ // giving you access to the request body data if you want to use it yourself
50
+ " body" -> request.text()
51
+ )
52
+ }
53
+
54
54
@ cask.postForm(" /form-extra" )
55
55
def formEndpointExtra (value1 : cask.FormValue ,
56
56
value2 : Seq [Int ],
You can’t perform that action at this time.
0 commit comments