mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-03-12 00:45:34 +00:00
check if param 'limit' in doSearchByAttr() is set, before using it
This commit is contained in:
parent
5cb159ca82
commit
32c09408d4
|
@ -1277,7 +1277,7 @@ function doSearchByAttr($request, $response) { /* {{{ */
|
|||
$params = $request->getQueryParams();
|
||||
$attrname = $params['name'];
|
||||
$query = $params['value'];
|
||||
if(!$limit = $params['limit'])
|
||||
if(empty($params['limit']) || !$limit = $params['limit'])
|
||||
$limit = 50;
|
||||
$attrdef = $dms->getAttributeDefinitionByName($attrname);
|
||||
$entries = array();
|
||||
|
|
Loading…
Reference in New Issue
Block a user