Skip to content

Commit

Permalink
fix: 循环
Browse files Browse the repository at this point in the history
  • Loading branch information
ikechan8370 committed Feb 21, 2024
1 parent ba3422c commit c46c8fe
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions apps/vocal.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,10 @@ export class Vocal extends plugin {
if (description === '额度' || description === 'credit' || description === '余额') {
let sessTokens = Config.sunoSessToken.split(',')
let clientTokens = Config.sunoClientToken.split(',')
let tried = 0
let msg = ''
while (tried < sessTokens.length) {
let index = tried
let sess = sessTokens[index]
let clientToken = clientTokens[index]
for (let i = 0; i < sessTokens.length; i++) {
let sess = sessTokens[i]
let clientToken = clientTokens[i]
let client = new SunoClient({ sessToken: sess, clientToken })
let { credit, email } = await client.queryCredit()
logger.info({ credit, email })
Expand Down

0 comments on commit c46c8fe

Please sign in to comment.