Platine etape 1
This commit is contained in:
@@ -4,14 +4,12 @@ import { eventHandler } from 'h3'
|
||||
import { getCardFromDate } from '../../../utils/cards'
|
||||
|
||||
export default eventHandler(async (event) => {
|
||||
const basePath = path.join(process.cwd(), '/mnt/media/files/music')
|
||||
const dirPath = path.join(process.cwd(), '/mnt/media/files/music')
|
||||
const urlPrefix = `https://files.erudi.fr/music`
|
||||
|
||||
try {
|
||||
let allTracks: any[] = []
|
||||
|
||||
const dirPath = basePath
|
||||
const urlPrefix = `https://files.erudi.fr/music`
|
||||
|
||||
let files = await fs.promises.readdir(dirPath)
|
||||
files = files.filter((f) => !f.startsWith('.') && !f.endsWith('.jpg'))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user