fix: multiple_account被覆盖为未定义

This commit is contained in:
shanmite 2021-06-04 22:20:42 +08:00
parent fc9b3bacdd
commit 31b20ea39c
2 changed files with 3 additions and 1 deletions

View File

@ -133,6 +133,8 @@ curl -fsSL https://cdn.jsdelivr.net/gh/shanmite/LotteryAutoScript@main/script/do
进入`lottery`文件夹
编辑`env.js`与`my_config.json`文件
- env.js 设置必要环境变量
- my_config.json 写入你要覆盖的默认设置
执行相应的脚本

View File

@ -12,7 +12,7 @@ async function main() {
const { COOKIE, NUMBER, CLEAR, PAT, LOCALLAUNCH, ENABLE_MULTIPLE_ACCOUNT, MULTIPLE_ACCOUNT } = process.env;
if (LOCALLAUNCH || PAT) {
if (ENABLE_MULTIPLE_ACCOUNT) {
let muti_acco = multiple_account.length
let muti_acco = multiple_account && multiple_account.length
? multiple_account
: JSON.parse(MULTIPLE_ACCOUNT);