discourse/app/assets/javascripts/admin/models/site-text.js

Failed to ignore revisions in .git-blame-ignore-revs.

12 lines
339 B
JavaScript
Raw Normal View History

2018-06-15 11:03:24 -04:00
import { ajax } from "discourse/lib/ajax";
import RestModel from "discourse/models/rest";
const { getProperties } = Ember;
export default RestModel.extend({
revert() {
return ajax(`/admin/customize/site_texts/${this.id}`, {
type: "DELETE"
2018-06-15 11:03:24 -04:00
}).then(result => getProperties(result.site_text, "value", "can_revert"));
}
});