Skip to content

Commit

Permalink
Make regex for cleaning description narrower (#1029)
Browse files Browse the repository at this point in the history
  • Loading branch information
hidden4003 authored Aug 31, 2024
1 parent 8c27c00 commit 52e6796
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/Collection/CleanDescription.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import cx from 'classnames';
// The question marks are there because people can't spell…
const RemoveSummaryRegex = /\b(Sour?ce|Note|Summ?ary):([^\r\n]+|$)/mg;

const RemoveBasedOnWrittenByRegex = /^(\*|\u2014) ([^\r\n]+|$)/mg;
const RemoveBasedOnWrittenByRegex = /^(\*|\u2014) (based on|written by) ([^\r\n]+|$)/img;

const RemoveBBCodeRegex = /\[i\].*\[\/i\]/sg;
const RemoveBBCodeRegex = /\[i\](.*?)\[\/i\]/sg;

const MultiSpacesRegex = /\s{2,}/g;

Expand Down

0 comments on commit 52e6796

Please sign in to comment.