Skip to content

Commit

Permalink
Fix malformed regex in telegram link processor
Browse files Browse the repository at this point in the history
  • Loading branch information
lloydtorres committed Mar 23, 2016
1 parent cb5e6a9 commit 0c44ee0
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1055,9 +1055,9 @@ public static void setBbCodeFormatting(Context c, TextView t, String content)
setStyledTextView(c, t, holder);
}

public static final Pattern NS_TG_RAW_NATION_LINK = Pattern.compile("(?i)<a href=\"(?:" + BASE_URI_REGEX + "|)nation=(\\w.*?)\" rel=\"nofollow\">(.*?)<\\/a>");
public static final Pattern NS_TG_RAW_REGION_LINK_TG = Pattern.compile("(?i)<a href=\"(?:" + BASE_URI_REGEX + "|)region=(\\w.*?)\\?tgid=[0-9].*\" rel=\"nofollow\">(.*?)<\\/a>");
public static final Pattern NS_TG_RAW_REGION_LINK = Pattern.compile("(?i)<a href=\"(?:" + BASE_URI_REGEX + "|)region=(\\w.*?)\" rel=\"nofollow\">(.*?)<\\/a>");
public static final Pattern NS_TG_RAW_NATION_LINK = Pattern.compile("(?i)<a href=\"(?:" + BASE_URI_REGEX + "|)nation=(\\w*?)\" rel=\"nofollow\">(.*?)<\\/a>");
public static final Pattern NS_TG_RAW_REGION_LINK_TG = Pattern.compile("(?i)<a href=\"(?:" + BASE_URI_REGEX + "|)region=(\\w*?)\\?tgid=[0-9].*\" rel=\"nofollow\">(.*?)<\\/a>");
public static final Pattern NS_TG_RAW_REGION_LINK = Pattern.compile("(?i)<a href=\"(?:" + BASE_URI_REGEX + "|)region=(\\w*?)\" rel=\"nofollow\">(.*?)<\\/a>");
public static final Pattern PARAGRAPH = Pattern.compile("(?i)(?s)<p>(.*?)<\\/p>");

/**
Expand Down

0 comments on commit 0c44ee0

Please sign in to comment.