From: Eugen Rochko Date: Tue, 20 Apr 2021 00:34:08 +0000 (+0200) Subject: Fix newlines not being considered sentence separators in account note (#16079) X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=b5ac17c4b6bfa85494fd768bbf1af87ca79b622b;p=mastodon.git Fix newlines not being considered sentence separators in account note (#16079) Also bullets --- diff --git a/app/javascript/mastodon/features/follow_recommendations/components/account.js b/app/javascript/mastodon/features/follow_recommendations/components/account.js index 23c03d1ff..bd855aab0 100644 --- a/app/javascript/mastodon/features/follow_recommendations/components/account.js +++ b/app/javascript/mastodon/features/follow_recommendations/components/account.js @@ -27,7 +27,7 @@ const makeMapStateToProps = () => { }; const getFirstSentence = str => { - const arr = str.split(/(([\.\?!]+\s)|[.。?!])/); + const arr = str.split(/(([\.\?!]+\s)|[.。?!\n•])/); return arr[0]; };