Ver Fonte

Allow underscores in hashtags.

default há 1 ano atrás
pai
commit
29caa37fd7
1 ficheiros alterados com 1 adições e 1 exclusões
  1. 1 1
      activitypub.c

+ 1 - 1
activitypub.c

@@ -724,7 +724,7 @@ xs_str *process_tags(snac *snac, const char *content, xs_list **tag)
         /* use this same server */
         /* use this same server */
         def_srv = xs_dup(xs_dict_get(srv_config, "host"));
         def_srv = xs_dup(xs_dict_get(srv_config, "host"));
 
 
-    split = xs_regex_split(content, "(@[A-Za-z0-9_]+(@[A-Za-z0-9\\.-]+)?|&#[0-9]+;|#[^[:punct:][:space:]]+)");
+    split = xs_regex_split(content, "(@[A-Za-z0-9_]+(@[A-Za-z0-9\\.-]+)?|&#[0-9]+;|#(_|[^[:punct:][:space:]])+)");
 
 
     p = split;
     p = split;
     while (xs_list_iter(&p, &v)) {
     while (xs_list_iter(&p, &v)) {