diff --git a/src/platform/guards/platform-auth.guard.ts b/src/platform/guards/platform-auth.guard.ts index 665c835..d98c855 100644 --- a/src/platform/guards/platform-auth.guard.ts +++ b/src/platform/guards/platform-auth.guard.ts @@ -43,6 +43,7 @@ export class PlatformAuthGuard implements CanActivate { return true; } catch (error) { + console.log({token}) throw new UnauthorizedException('令牌验证失败'); } } diff --git a/src/templates/n8nTemplate.ts b/src/templates/n8nTemplate.ts index 84db6ef..70be560 100644 --- a/src/templates/n8nTemplate.ts +++ b/src/templates/n8nTemplate.ts @@ -33,7 +33,7 @@ export abstract class N8nImageGenerateTemplate extends ImageGenerateTemplate { }) .then((res) => res.data) .then((res) => { - + if(res.task_id) return res.task_id throw new Error(res.msg); }); }