mirror of
https://github.com/badlogic/heissepreise.git
synced 2024-06-20 07:25:50 +02:00
style: 🔥 remove unused variables
This commit is contained in:
parent
37d79200c0
commit
f497f1259f
|
@ -1,5 +1,4 @@
|
|||
const fs = require("fs");
|
||||
const axios = require("axios");
|
||||
const stores = require("./stores");
|
||||
|
||||
const STORE_KEYS = Object.keys(stores);
|
||||
|
|
2
index.js
2
index.js
|
@ -10,7 +10,7 @@ const analysis = require("./analysis");
|
|||
|
||||
if (fs.existsSync(`${dataDir}/latest-canonical.json`)) {
|
||||
fs.copyFileSync(`${dataDir}/latest-canonical.json`, `site/latest-canonical.json`);
|
||||
analysis.updateData(dataDir, (newItems) => {
|
||||
analysis.updateData(dataDir, (_newItems) => {
|
||||
fs.copyFileSync(`${dataDir}/latest-canonical.json`, `site/latest-canonical.json`);
|
||||
});
|
||||
} else {
|
||||
|
|
|
@ -2,7 +2,6 @@ let changeDates = [];
|
|||
let items = [];
|
||||
|
||||
async function load() {
|
||||
const today = currentDate();
|
||||
items = await loadItems();
|
||||
items.sort((a, b) => {
|
||||
if (a.store < b.store) {
|
||||
|
@ -29,9 +28,9 @@ async function load() {
|
|||
showResults(items, currentDate());
|
||||
}
|
||||
|
||||
function showResults(items, today) {
|
||||
function showResults(items, _today) {
|
||||
const storeCheckboxes = STORE_KEYS.map(store => document.querySelector(`#${store}`));
|
||||
const checkedStores = STORE_KEYS.filter((store, i) => storeCheckboxes[i].checked)
|
||||
const checkedStores = STORE_KEYS.filter((_store, i) => storeCheckboxes[i].checked)
|
||||
let changedItems = [];
|
||||
for (item of items) {
|
||||
if (item.priceHistory.length < 2) continue;
|
||||
|
|
|
@ -2,7 +2,6 @@ let changeDates = [];
|
|||
let items = [];
|
||||
|
||||
async function load() {
|
||||
const today = currentDate();
|
||||
items = await loadItems();
|
||||
items.sort((a, b) => {
|
||||
if (a.store < b.store) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user