MDL-15488, move search_result flag to ws.php
This commit is contained in:
@@ -151,7 +151,6 @@ class repository_flickr_public extends repository {
|
||||
$SESSION->$sess_text = $search_text;
|
||||
}
|
||||
$ret = array();
|
||||
$ret['search_result'] = true;
|
||||
return $this->build_list($photos, $page, &$ret);
|
||||
}
|
||||
|
||||
|
||||
@@ -801,7 +801,6 @@ abstract class repository {
|
||||
* 'manage' => (string) link to file manager,
|
||||
* 'nologin' => (bool) requires login,
|
||||
* 'nosearch' => (bool) no search link,
|
||||
* 'search_result' => (bool) this list is a searching result,
|
||||
* 'upload' => array( // upload manager
|
||||
* 'name' => (string) label of the form element,
|
||||
* 'id' => (string) id of the form element
|
||||
|
||||
+3
-1
@@ -142,7 +142,9 @@ EOD;
|
||||
break;
|
||||
case 'search':
|
||||
try {
|
||||
echo json_encode($repo->search($search_text));
|
||||
$search_result = $repo->search($search_text);
|
||||
$search_result['search_result'] = true;
|
||||
echo json_encode($search_result);
|
||||
} catch (repository_exception $e) {
|
||||
$err = new stdclass;
|
||||
$err->e = $e->getMessage();
|
||||
|
||||
Reference in New Issue
Block a user