DEV: apply new coding standards (#10592)

This commit is contained in:
Joffrey JAFFEUX
2020-09-04 13:42:47 +02:00
committed by GitHub
parent 80dfaeb0d2
commit 52672b9eab
1473 changed files with 9386 additions and 9958 deletions

View File

@ -11,8 +11,8 @@ export default Controller.extend({
filter: null,
@observes("filter")
show: discourseDebounce(function() {
Permalink.findAll(this.filter).then(result => {
show: discourseDebounce(function () {
Permalink.findAll(this.filter).then((result) => {
this.set("model", result);
this.set("loading", false);
});
@ -33,28 +33,28 @@ export default Controller.extend({
textArea.remove();
},
destroy: function(record) {
destroy: function (record) {
return bootbox.confirm(
I18n.t("admin.permalink.delete_confirm"),
I18n.t("no_value"),
I18n.t("yes_value"),
result => {
(result) => {
if (result) {
record.destroy().then(
deleted => {
(deleted) => {
if (deleted) {
this.model.removeObject(record);
} else {
bootbox.alert(I18n.t("generic_error"));
}
},
function() {
function () {
bootbox.alert(I18n.t("generic_error"));
}
);
}
}
);
}
}
},
},
});