We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e2bd1d2 commit da7df4dCopy full SHA for da7df4d
course-matrix/frontend/src/pages/Home/Home.tsx
@@ -73,10 +73,10 @@ const Home = () => {
73
) : (
74
[...data]
75
.sort((a: Timetable, b: Timetable) => {
76
- if(a.favorite==b.favorite)
77
- return (b?.updated_at.localeCompare(a?.updated_at));
78
- if(a.favorite) return 1;
79
- if(b.favorite) return -1;
+ if (a.favorite == b.favorite)
+ return b?.updated_at.localeCompare(a?.updated_at);
+ if (a.favorite) return 1;
+ if (b.favorite) return -1;
80
return 0;
81
})
82
.map((timetable) => (
0 commit comments