mirror of
https://github.com/shanmiteko/LotteryAutoScript.git
synced 2026-06-12 21:03:13 +08:00
feat: clear_dynamic_type类型可以多选(#42)
This commit is contained in:
parent
1c8e5915d9
commit
b5fdb2d247
@ -68,7 +68,11 @@ async function clear() {
|
||||
for (const [index, dyinfo] of allModifyDynamicResArray.entries()) {
|
||||
log.info('清理动态', `第${page + 1}页中的第${index + 1}个动态`)
|
||||
const { type, dynamic_id, createtime } = dyinfo || {};
|
||||
if (type === clear_dynamic_type) {
|
||||
if (typeof type !== 'undefined'
|
||||
&& clear_dynamic_type instanceof Array
|
||||
? clear_dynamic_type.includes(type)
|
||||
: clear_dynamic_type === type
|
||||
) {
|
||||
const
|
||||
{ origin_uid } = dyinfo,
|
||||
days_ago = (Now - createtime) / 86400;
|
||||
|
||||
@ -256,8 +256,12 @@ module.exports = Object.freeze({
|
||||
* | 番剧 | `512` |
|
||||
* | 活动 | `2048` |
|
||||
* | 专栏 | `64` |
|
||||
*
|
||||
* @example
|
||||
* 1
|
||||
* [1,2,4]
|
||||
*/
|
||||
clear_dynamic_type: 1
|
||||
clear_dynamic_type: [1]
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "lottery-auto-script",
|
||||
"version": "2.2.2",
|
||||
"version": "2.2.3",
|
||||
"description": "自动参与B站动态抽奖",
|
||||
"main": "main.js",
|
||||
"scripts": {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user