Skip to content

Commit

Permalink
Merge pull request #37 from HyeokjinKang/develop
Browse files Browse the repository at this point in the history
fix: rankHistory 표기 순서 변경
  • Loading branch information
Coupy authored Aug 22, 2023
2 parents c607fdf + 9714e9d commit aef15a4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion public/js/game.js
Original file line number Diff line number Diff line change
Expand Up @@ -1419,7 +1419,8 @@ const profileUpdate = async (uid) => {
if (rankHistory.length == 0) labels.push(`${`${day.getMonth() + 1}`.padStart(2, "0")}-${`${day.getDate() + 1}`.padStart(2, "0")}`);
labels.push(`${`${day.getMonth() + 1}`.padStart(2, "0")}-${`${day.getDate() + 1}`.padStart(2, "0")}`);
}
let data = [rank, ...rankHistory];
labels.reverse();
let data = [...rankHistory, rank];
if (rankHistory.length == 0) data.push(rank);
const chart = document.getElementById("rankChart");
const chartCtx = chart.getContext("2d");
Expand Down

0 comments on commit aef15a4

Please sign in to comment.