Reverse avatar history

This commit is contained in:
Natsumi
2023-02-12 00:19:02 +13:00
parent 403578ec8e
commit b5916d0a50

View File

@@ -21955,7 +21955,7 @@ speechSynthesis.getVoices();
API.$on('LOGIN', async function () { API.$on('LOGIN', async function () {
$app.avatarHistory = new Set(); $app.avatarHistory = new Set();
var historyArray = await database.getAvatarHistory(); var historyArray = await database.getAvatarHistory();
$app.avatarHistoryArray = historyArray; $app.avatarHistoryArray = historyArray.reverse();
for (var i = 0; i < historyArray.length; i++) { for (var i = 0; i < historyArray.length; i++) {
$app.avatarHistory.add(historyArray[i].id); $app.avatarHistory.add(historyArray[i].id);
this.applyAvatar(historyArray[i]); this.applyAvatar(historyArray[i]);