mirror of
https://codeberg.org/Bazsalanszky/Infinity-For-Lemmy.git
synced 2024-12-30 21:07:11 +01:00
Fix an issue in modifyMarkdown(String markdown) in Utils.Utils about matching subreddits and users.
This commit is contained in:
parent
331704e5ef
commit
285bb0c385
@ -34,7 +34,7 @@ public class Utils {
|
||||
private static final long YEAR_MILLIS = 12 * MONTH_MILLIS;
|
||||
|
||||
public static String modifyMarkdown(String markdown) {
|
||||
StringBuilder regexed = new StringBuilder(markdown.replaceAll("((?<=[\\s])|^)/{0,1}[rRuU]/[\\w-]+/{0,1}", "[$0](https://www.reddit.com/$0)"));
|
||||
StringBuilder regexed = new StringBuilder(markdown.replaceAll("((?<=[\\s])|^)/[rRuU]/[\\w-]+/{0,1}", "[$0](https://www.reddit.com$0)").replaceAll("((?<=[\\s])|^)[rRuU]/[\\w-]+/{0,1}", "[$0](https://www.reddit.com/$0)"));
|
||||
|
||||
int startIndex = 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user