Let's use AI to Earn!
TypeScript auto-publishdouyindouyin-apielectron-appelectron-reactkuaishoukwaipublishedshipinhaotoolxiaohongshu
排查不互动
daoyian3a2f38ec5941
diff --git a/electron/main/interaction/service.ts b/electron/main/interaction/service.tsindex b463ac27..87cc013a 100644--- a/electron/main/interaction/service.ts+++ b/electron/main/interaction/service.ts@@ -139,6 +139,7 @@ export class InteractionService {const commentContentList = option.commentContent? option.commentContent.split(','): [];+ console.log('------ commentContentList ----', commentContentList);// return;const userInfo = getUserInfo();@@ -250,7 +251,7 @@ export class InteractionService {option.commentProb === 0? false: !option.commentProb || Math.random() * 100 < option.commentProb;- let commentWorksRes;+ let commentWorksRes: any = {};if (shouldComment) {// if (option.commentContent.includes(',')) {@@ -303,6 +304,8 @@ export class InteractionService {? false: !option.likeProb || randomLike < option.likeProb;+ console.log('------ shouldLike', shouldLike);+if (shouldLike) {try {console.log('------ 开始点赞作品:', works.dataId, works.author?.id);@@ -366,7 +369,7 @@ export class InteractionService {let commentRemark = '';if (commentWorksRes.data) {- if (commentWorksRes.data.msg) {+ if (commentWorksRes.data?.msg) {commentRemark = commentWorksRes.data.msg;} else {commentRemark = commentWorksRes.data.toast;@@ -505,7 +508,8 @@ export class InteractionService {// 获取自动互动列表async getAutorInteractionList(account: any, worksList: any, option: any) {- return await this.autorInteraction(+ console.log('------ server option.commentContent ----', option.commentContent);+ return await this.autorInteraction(account,worksList,{@@ -514,7 +518,7 @@ export class InteractionService {likeProb: 999, // 点赞概率collectProb: 999, // 收藏概率commentProb: 999, // 评论概率- commentType: 'ai', // 评论类型+ commentType: option.commentContent?'custom' : 'ai', // 评论类型},(e: {tag: AutorWorksInteractionScheduleEvent;diff --git a/electron/main/plat/PlatformBase.ts b/electron/main/plat/PlatformBase.tsindex e207440b..295f8515 100644--- a/electron/main/plat/PlatformBase.ts+++ b/electron/main/plat/PlatformBase.ts@@ -91,7 +91,7 @@ export abstract class PlatformBase {account: AccountModel,dataId: string,option?: any,- ): Promise<boolean>;+ ): Promise<any>;/*** 收藏@@ -101,7 +101,7 @@ export abstract class PlatformBase {abstract shoucangDyOther(account: AccountModel,pcursor?: string,- ): Promise<boolean>;+ ): Promise<any>;/*** 获取作品列表