DEV: Convert to native class syntax (#110)

This commit is contained in:
David Taylor 2024-11-29 15:43:16 +00:00 committed by GitHub
parent 5c64887dc9
commit ff810c65d8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 3 deletions

View File

@ -1,9 +1,9 @@
import RestAdapter from "discourse/adapters/rest";
import { ajax } from "discourse/lib/ajax";
export default RestAdapter.extend({
export default class UserNote extends RestAdapter {
destroyRecord(store, type, record) {
const path = this.pathFor(store, type, record.id);
return ajax(`${path}?user_id=${record.user_id}`, { method: "DELETE" });
},
});
}
}