mirror of
https://github.com/discourse/discourse-subscriptions.git
synced 2025-03-06 17:49:24 +00:00
if not a category route remove body class
This commit is contained in:
parent
c4c96046cd
commit
a3636a5038
@ -13,12 +13,13 @@ createWidget('category-header-widget', {
|
|||||||
tagName: 'span',
|
tagName: 'span',
|
||||||
|
|
||||||
html(args) {
|
html(args) {
|
||||||
if (args.currentPath.toLowerCase().indexOf('category') === -1) return;
|
|
||||||
|
|
||||||
const controller = this.register.lookup('controller:navigation/category');
|
const controller = this.register.lookup('controller:navigation/category');
|
||||||
const category = controller.get("category");
|
const category = controller.get("category");
|
||||||
|
|
||||||
if (category && category.donations_cause) {
|
if (args.currentPath.toLowerCase().indexOf('category') > -1 &&
|
||||||
|
category &&
|
||||||
|
category.donations_cause) {
|
||||||
$("body").addClass("donations-category");
|
$("body").addClass("donations-category");
|
||||||
|
|
||||||
let contents = [
|
let contents = [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user