Skip to content

Commit

Permalink
hide button after photo approve
Browse files Browse the repository at this point in the history
  • Loading branch information
alexey-pd committed Jul 13, 2024
1 parent 6c5d6fa commit 84906e4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/bot/conversations/admin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ export function adminConversation(channelId: string) {

if (fileId) {
await ctx.api.sendPhoto(channelId, fileId);
await ctx.editMessageReplyMarkup({ reply_markup: { inline_keyboard: [] } });
}
},
ADMIN_CONVERSATION,
Expand Down
4 changes: 2 additions & 2 deletions src/bot/features/send/send.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ export async function sendPhoto(ctx: Context, fileId: string, other?: Other<RawA
caption: `@${ctx.from?.username || ctx.from?.first_name}`,
};

await ctx.reply(`Thanks for the photo!`);

await ctx.api.sendPhoto(
adminId,
fileId,
params,
);

await ctx.reply(`Thanks for the photo!`);
}

0 comments on commit 84906e4

Please sign in to comment.