mirror of
https://github.com/discourse/discourse.git
synced 2024-11-29 05:43:39 +08:00
14 lines
361 B
JavaScript
14 lines
361 B
JavaScript
/**
|
|
Handles when you click the Site Settings tab in admin, but haven't
|
|
chosen a category. It will redirect to the first category.
|
|
**/
|
|
export default Discourse.Route.extend({
|
|
beforeModel() {
|
|
this.replaceWith(
|
|
"adminSiteSettingsCategory",
|
|
this.controllerFor("adminSiteSettings").get("visibleSiteSettings")[0]
|
|
.nameKey
|
|
);
|
|
}
|
|
});
|