mirror of
https://github.com/ZZZure/ZZZ-Plugin.git
synced 2025-12-16 21:27:47 +00:00
移除apps插件非必要return false,拦截指令向后传递 #138
This commit is contained in:
parent
3273f256fc
commit
9d676fa70a
17 changed files with 82 additions and 173 deletions
|
|
@ -54,8 +54,7 @@ export async function hasUpdate() {
|
|||
/** 开启/关闭自动更新推送 */
|
||||
export async function enableAutoUpdatePush() {
|
||||
if (!this.e.isMaster) {
|
||||
this.reply('仅限主人设置', false, { at: true, recallMsg: 100 });
|
||||
return false;
|
||||
return this.reply('仅限主人设置', false, { at: true, recallMsg: 100 });
|
||||
}
|
||||
let enable = true;
|
||||
if (this.e.msg.includes('关闭')) {
|
||||
|
|
@ -72,12 +71,11 @@ export async function enableAutoUpdatePush() {
|
|||
/** 设置自动更新时间 */
|
||||
export async function setCheckUpdateCron() {
|
||||
if (!this.e.isMaster) {
|
||||
this.reply('仅限主人设置', false, { at: true, recallMsg: 100 });
|
||||
return false;
|
||||
return this.reply('仅限主人设置', false, { at: true, recallMsg: 100 });
|
||||
}
|
||||
const cron = this.e.msg.split('时间')[1];
|
||||
if (!cron) {
|
||||
await this.reply(
|
||||
return this.reply(
|
||||
`[${pluginName}]设置自动更新频率失败,无cron表达式`,
|
||||
false,
|
||||
{
|
||||
|
|
@ -85,7 +83,6 @@ export async function setCheckUpdateCron() {
|
|||
recallMsg: 100,
|
||||
}
|
||||
);
|
||||
return false;
|
||||
}
|
||||
settings.setSingleConfig('config', 'update', { cron });
|
||||
await this.reply(`[${pluginName}]自动更新频率已设置为${cron}`, false, {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue