diff options
Diffstat (limited to 'html.c')
| -rw-r--r-- | html.c | 20 |
1 files changed, 16 insertions, 4 deletions
| @@ -1324,8 +1324,14 @@ xs_html *html_entry(snac *user, xs_dict *msg, int read_only, | |||
| 1324 | return NULL; | 1324 | return NULL; |
| 1325 | 1325 | ||
| 1326 | /* hidden? do nothing more for this conversation */ | 1326 | /* hidden? do nothing more for this conversation */ |
| 1327 | if (user && is_hidden(user, id)) | 1327 | if (user && is_hidden(user, id)) { |
| 1328 | return NULL; | 1328 | xs *s1 = xs_fmt("%s_entry", md5); |
| 1329 | |||
| 1330 | /* return just an dummy anchor, to keep position after hitting 'Hide' */ | ||
| 1331 | return xs_html_tag("div", | ||
| 1332 | xs_html_tag("a", | ||
| 1333 | xs_html_attr("name", s1))); | ||
| 1334 | } | ||
| 1329 | 1335 | ||
| 1330 | /* avoid too deep nesting, as it may be a loop */ | 1336 | /* avoid too deep nesting, as it may be a loop */ |
| 1331 | if (level >= 256) | 1337 | if (level >= 256) |
| @@ -1356,8 +1362,14 @@ xs_html *html_entry(snac *user, xs_dict *msg, int read_only, | |||
| 1356 | return NULL; | 1362 | return NULL; |
| 1357 | 1363 | ||
| 1358 | /* ignore muted morons immediately */ | 1364 | /* ignore muted morons immediately */ |
| 1359 | if (user && is_muted(user, actor)) | 1365 | if (user && is_muted(user, actor)) { |
| 1360 | return NULL; | 1366 | xs *s1 = xs_fmt("%s_entry", md5); |
| 1367 | |||
| 1368 | /* return just an dummy anchor, to keep position after hitting 'MUTE' */ | ||
| 1369 | return xs_html_tag("div", | ||
| 1370 | xs_html_tag("a", | ||
| 1371 | xs_html_attr("name", s1))); | ||
| 1372 | } | ||
| 1361 | 1373 | ||
| 1362 | if ((user == NULL || strcmp(actor, user->actor) != 0) | 1374 | if ((user == NULL || strcmp(actor, user->actor) != 0) |
| 1363 | && !valid_status(actor_get(actor, NULL))) | 1375 | && !valid_status(actor_get(actor, NULL))) |