no results also for "add link"

This commit is contained in:
azivner 2018-06-07 23:08:41 -04:00
parent 8211bed449
commit bdb5e2f13f

View File

@ -57,7 +57,15 @@ async function showDialog() {
source: async function(request, response) { source: async function(request, response) {
const result = await server.get('autocomplete?query=' + encodeURIComponent(request.term)); const result = await server.get('autocomplete?query=' + encodeURIComponent(request.term));
response(result); if (result.length > 0) {
response(result);
}
else {
response([{
label: "No results",
value: "No results"
}]);
}
}, },
minLength: 2, minLength: 2,
change: async () => { change: async () => {