fix: always inject FYP

This commit is contained in:
Thomas Zarebczan 2022-03-26 13:23:20 -04:00 committed by Thomas Zarebczan
parent 09fc18cc02
commit 79aa098484

View file

@ -94,7 +94,20 @@ function HomePage(props: Props) {
}
});
} else {
sortedRowData = rowData;
rowData.forEach((key) => {
// always inject FYP is homepage not customized, hide news.
if (key.id === 'FOLLOWING') {
sortedRowData.push(key);
sortedRowData.push({
id: 'FYP',
title: 'Recommended',
icon: ICONS.GLOBE,
link: `/$/${PAGES.FYP}`,
});
} else if (key.id !== 'NEWS') {
sortedRowData.push(key);
}
});
}
type SectionHeaderProps = {