Update api controller

This commit is contained in:
Daniel Supernault 2019-09-26 20:39:52 -06:00
parent 68e09477d0
commit 43c18e866c
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7

View file

@ -1133,7 +1133,7 @@ class ApiV1Controller extends Controller
abort_if(!$request->user(), 403); abort_if(!$request->user(), 403);
$this->validate($request, [ $this->validate($request, [
'page' => 'nullable|integer|min:1|max:10', 'page' => 'nullable|integer|min:1|max:10',
'limit' => 'nullable|integer|min:1|max:40', 'limit' => 'nullable|integer|min:1|max:80',
'max_id' => 'nullable|integer|min:1', 'max_id' => 'nullable|integer|min:1',
'min_id' => 'nullable|integer|min:0', 'min_id' => 'nullable|integer|min:0',
]); ]);
@ -1176,7 +1176,7 @@ class ApiV1Controller extends Controller
'page' => 'nullable|integer|max:40', 'page' => 'nullable|integer|max:40',
'min_id' => 'nullable|integer|min:0|max:' . PHP_INT_MAX, 'min_id' => 'nullable|integer|min:0|max:' . PHP_INT_MAX,
'max_id' => 'nullable|integer|min:0|max:' . PHP_INT_MAX, 'max_id' => 'nullable|integer|min:0|max:' . PHP_INT_MAX,
'limit' => 'nullable|integer|max:40' 'limit' => 'nullable|integer|max:80'
]); ]);
$page = $request->input('page'); $page = $request->input('page');
@ -1276,7 +1276,7 @@ class ApiV1Controller extends Controller
'page' => 'nullable|integer|max:40', 'page' => 'nullable|integer|max:40',
'min_id' => 'nullable|integer|min:0|max:' . PHP_INT_MAX, 'min_id' => 'nullable|integer|min:0|max:' . PHP_INT_MAX,
'max_id' => 'nullable|integer|min:0|max:' . PHP_INT_MAX, 'max_id' => 'nullable|integer|min:0|max:' . PHP_INT_MAX,
'limit' => 'nullable|integer|max:40' 'limit' => 'nullable|integer|max:80'
]); ]);
$page = $request->input('page'); $page = $request->input('page');