Skip to content

Commit

Permalink
Update _worker.js
Browse files Browse the repository at this point in the history
  • Loading branch information
jyx04 authored Jun 21, 2024
1 parent f842730 commit 020caa9
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions _worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -2722,27 +2722,6 @@ function combineData(usersData, historyData) {
return combinedData;
}

function generateHeaderRow(historyData) {
return historyData.map(h => `<th>GPT-4</th><th>GPT-3.5</th>`).join('');
}

function generateTimestampRow(historyData) {
return historyData.map(h => `<th colspan="2">${h.timestamp}</th>`).join('');
}

async function getHistoryData(queryType) {
const logType = queryType === 'plus' ? 'PlusUsageLogs' : 'FreeUsageLogs';
const historyLogs = await KV.get(logType);
return historyLogs ? JSON.parse(historyLogs) : [];
}











Expand Down

0 comments on commit 020caa9

Please sign in to comment.