aboutsummaryrefslogtreecommitdiff
path: root/src/services/status_parser/status_parser.js
diff options
context:
space:
mode:
authorlain <lain@soykaf.club>2020-06-11 18:39:19 +0200
committerlain <lain@soykaf.club>2020-06-11 18:39:19 +0200
commit8d7d4980b9a9c68e3c36dc00dfc85e39842b03f7 (patch)
tree6c8e6f41e52b434cb48638b0d1261025ea182e24 /src/services/status_parser/status_parser.js
parentdc7489fd8bfe9cb36358f934781c6ff4ca1e1fd0 (diff)
StatusParser: Remove unused removeAttachmentLinks.
Brings down the vendor by over 200kb
Diffstat (limited to 'src/services/status_parser/status_parser.js')
-rw-r--r--src/services/status_parser/status_parser.js15
1 files changed, 0 insertions, 15 deletions
diff --git a/src/services/status_parser/status_parser.js b/src/services/status_parser/status_parser.js
index 3d517e3c..ed0f6d57 100644
--- a/src/services/status_parser/status_parser.js
+++ b/src/services/status_parser/status_parser.js
@@ -1,17 +1,4 @@
import { filter } from 'lodash'
-import sanitize from 'sanitize-html'
-
-export const removeAttachmentLinks = (html) => {
- return sanitize(html, {
- allowedTags: false,
- allowedAttributes: false,
- exclusiveFilter: ({ tag, attribs }) => tag === 'a' && typeof attribs.class === 'string' && attribs.class.match(/attachment/)
- })
-}
-
-export const parse = (html) => {
- return removeAttachmentLinks(html)
-}
export const muteWordHits = (status, muteWords) => {
const statusText = status.text.toLowerCase()
@@ -22,5 +9,3 @@ export const muteWordHits = (status, muteWords) => {
return hits
}
-
-export default parse