@@ -36,16 +36,8 @@ module.exports = (crowi) => {
});
}
catch (err) {
- logger.error('Failed to create a page.');
- await client.chat.postEphemeral({
- channel: body.channel_id,
- user: body.user_id,
- text: 'Failed To Create',
- blocks: [
- markdownSectionBlock(`*Failed to create new page.*\n ${err}`),
- ],
- });
- throw err;
+ logger.error(err);
+ throw new Error('Failed to create page.');
};
@@ -25,7 +25,7 @@ module.exports = (crowi) => {
markdownSectionBlock('*Failed to search.*\n Hint\n `/growi search [keyword]`'),
],
- throw new Error('/growi command:search: Failed to search');
+ throw new Error('Failed to search.');
const appUrl = crowi.appService.getSiteUrl();