FIX: prevents create row to be displayed if term is in displayed list
This commit is contained in:
parent
ba2f01c0bd
commit
9b680fc45c
|
@ -1,4 +1,4 @@
|
|||
const { run } = Ember;
|
||||
const { run, get } = Ember;
|
||||
import { ajax } from "discourse/lib/ajax";
|
||||
import { popupAjaxError } from "discourse/lib/ajax-error";
|
||||
|
||||
|
@ -47,6 +47,10 @@ export default Ember.Mixin.create({
|
|||
return false;
|
||||
}
|
||||
|
||||
if (this.get("asyncContent").map(c => get(c, "id")).includes(term)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
},
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue