day of week selector

This commit is contained in:
2024-09-10 16:58:27 -06:00
parent ff520233d6
commit 6266879103
5 changed files with 51 additions and 13 deletions

View File

@@ -1,7 +1,6 @@
import { promises as fs } from "fs";
import path from "path";
import {
LocalCourse,
LocalCourseSettings,
localCourseYamlUtils,
} from "@/models/local/localCourse";
@@ -28,18 +27,6 @@ const basePath = process.env.STORAGE_DIRECTORY ?? "./storage";
console.log("base path", basePath);
export const fileStorageService = {
// async saveCourseAsync(
// course: LocalCourse,
// previouslyStoredCourse?: LocalCourse
// ) {
// await courseMarkdownSaver.save(course, previouslyStoredCourse);
// },
// async loadSavedCourses(): Promise<LocalCourse[]> {
// console.log("loading pages from file system");
// return (await courseMarkdownLoader.loadSavedCourses()) || [];
// },
async getCourseNames() {
console.log("loading course ids");
const courseDirectories = await fs.readdir(basePath, {