Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Thanks to: @dathbe.
- [refactor] Add new file `js/module_functions.js` to move code used in several modules to one place (#3837)
- [tests] refactor: simplify jest config file (#3844)
- [tests] refactor: extract constants for weather electron tests (#3845)
- [tests] replace `console` with `Log` in calendar `debug.js` to avoid exception in eslint config (#3846)

### Updated

Expand Down
1 change: 0 additions & 1 deletion eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ export default defineConfig([
files: ["**/*.js"],
ignores: [
"clientonly/index.js",
"modules/default/calendar/debug.js",
"js/logger.js",
"tests/**/*.js"
],
Expand Down
13 changes: 7 additions & 6 deletions modules/default/calendar/debug.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
*/
// Alias modules mentioned in package.js under _moduleAliases.
require("module-alias/register");
const Log = require("../../../js/logger");

const CalendarFetcher = require("./calendarfetcher");

Expand All @@ -20,22 +21,22 @@ const auth = {
pass: pass
};

console.log("Create fetcher ...");
Log.log("Create fetcher ...");

const fetcher = new CalendarFetcher(url, fetchInterval, [], maximumEntries, maximumNumberOfDays, auth);

fetcher.onReceive(function (fetcher) {
console.log(fetcher.events());
console.log("------------------------------------------------------------");
Log.log(fetcher.events());
Log.log("------------------------------------------------------------");
process.exit(0);
});

fetcher.onError(function (fetcher, error) {
console.log("Fetcher error:");
console.log(error);
Log.log("Fetcher error:");
Log.log(error);
process.exit(1);
});

fetcher.startFetch();

console.log("Create fetcher done! ");
Log.log("Create fetcher done! ");