Compare commits

..

3 Commits

Author SHA1 Message Date
pinks ffd3d0dc8d fix: priority for img2img 2023-11-18 00:50:34 +01:00
pinks ec4a3c893e fix: clearing paused reason 2023-11-18 00:49:39 +01:00
pinks e7d292df60 fix type error 2023-11-17 19:22:35 +01:00
3 changed files with 5 additions and 3 deletions

View File

@ -40,7 +40,9 @@ export async function getConfig(): Promise<Config> {
export async function setConfig(newConfig: Partial<Config>): Promise<void> {
const oldConfig = await getConfig();
const config: Config = {
pausedReason: newConfig.pausedReason ?? oldConfig.pausedReason,
pausedReason: newConfig.pausedReason === undefined
? oldConfig.pausedReason
: newConfig.pausedReason,
maxUserJobs: newConfig.maxUserJobs ?? oldConfig.maxUserJobs,
maxJobs: newConfig.maxJobs ?? oldConfig.maxJobs,
defaultParams: newConfig.defaultParams ?? oldConfig.defaultParams,

View File

@ -129,7 +129,7 @@ async function img2img(
chat: ctx.message.chat,
requestMessage: ctx.message,
replyMessage: replyMessage,
}, { retryCount: 3, repeatDelayMs: 10_000 });
}, { priority: 0, retryCount: 3, repeatDelayMs: 10_000 });
debug(`Generation (img2img) enqueued for ${formatUserChat(ctx.message)}`);
}

View File

@ -39,7 +39,7 @@ async function pnginfo(ctx: ErisContext, includeRepliedTo: boolean): Promise<voi
const buffer = await fetch(file.getUrl()).then((resp) => resp.arrayBuffer());
const info = getPngInfo(buffer);
if (!info) {
return await ctx.reply(
return void await ctx.reply(
"No info found in file.",
omitUndef({ reply_to_message_id: ctx.message?.message_id }),
);