This commit is contained in:
parent
5bf0f8ac62
commit
0fab52a16b
@ -30,10 +30,22 @@ export default function Scores({
|
||||
|
||||
const router = useRouter();
|
||||
|
||||
const lastUsedSortType = settingsStore?.lastUsedSortType;
|
||||
if (lastUsedSortType && lastUsedSortType != sortType) {
|
||||
router.push(
|
||||
`/player/${playerId}/scoresaber/${lastUsedSortType.value}/${page}`,
|
||||
{
|
||||
scroll: false,
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
function setPage(page: number, sortTypee?: SortType) {
|
||||
if (sortTypee) {
|
||||
if (sortTypee.value !== sortType.value) {
|
||||
settingsStore?.setLastUsedSortType(sortTypee);
|
||||
}
|
||||
}
|
||||
router.push(
|
||||
`/player/${playerId}/scoresaber/${
|
||||
sortTypee ? sortTypee.value : sortType.value
|
||||
|
Loading…
Reference in New Issue
Block a user