refactor(thumbnail): 优化缩略图生成逻辑并移除元数据文件

重构缩略图生成逻辑,使用动态文件名包含处理参数
移除不再需要的元数据文件处理代码
清理临时文件时增加对视频帧临时文件的处理
This commit is contained in:
2026-01-08 12:17:46 +08:00
parent 755f8d45c3
commit e50df0eaf6
2 changed files with 16 additions and 20 deletions

2
new.js
View File

@@ -8,7 +8,7 @@ const EventEmitter = require('events');
// Configuration
const PORT = process.env.PORT || 9520;
const API_BASE = 'http://127.0.0.1:9558/api';
const API_BASE = process.env.API_BASE || 'http://127.0.0.1:9558/api';
const CACHE_DIR = process.env.CACHE_DIR ? path.resolve(process.env.CACHE_DIR) : path.join(__dirname, '.cache');
// Ensure cache directory exists