This repository was archived by the owner on Dec 15, 2022. It is now read-only.
This repository was archived by the owner on Dec 15, 2022. It is now read-only.
filePath should be escaped for markdown in notifications #117
Open
Description
File name can be shown incorrectly in notification. The sequence \.
is turned into .
— for example, it is read as "\Users\user.atom\packages" instead of "\Users\user.atom\packages".
The issue is that atom.notifications.addError
function interprets message as in Markdown markup. So, filePath
should be properly escaped in a code like:
atom.notifications?.addError("Failed to load snippets from '#{filePath}'", {detail: error.message, dismissable: true})