Permalink
Browse files

trim comments

  • Loading branch information...
theopolisme committed Nov 8, 2013
1 parent 4e39dd3 commit 4217c2d4ae15acaa9703f3c3b995ddc3a93b2291
Showing with 4 additions and 3 deletions.
  1. +4 −3 src/submissions.js
@@ -1613,10 +1613,11 @@ function afcHelper_page_creator(title) {
}
function afcHelper_addcomment(comment) {
if (comment == "")
return "";
var trimmed_comment = $.trim(comment);
if (trimmed_comment !== "")
return "\{\{afc comment|1=" + trimmed_comment + " \~\~\~\~\}\}";
else
return "\{\{afc comment|1=" + comment + " \~\~\~\~\}\}";
return "";
}
function afcHelper_underreview() {

2 comments on commit 4217c2d

@wikipedia-mabdul

This comment has been minimized.

Member

wikipedia-mabdul replied Nov 10, 2013

shouldn't that be done in ffu.js, too?

https://github.com/WPAFC/afch/blob/develop/src/ffu.js#L367

} else if (sub_m.action == 'comment') {
       if ((sub_m.prefmtcomment != '') && (sub_m.prefmtcomment != 'custom')) {
              if (sub_m.comment == '') text += '\n:\{\{subst:ffu|' + sub_m.prefmtcomment + '\}\} \~\~\~\~\n';
              else text += '\n:\{\{subst:ffu|' + sub_m.prefmtcomment + '\}\} ' + sub_m.comment + ' \~\~\~\~\n';
} else if (sub_m.comment != '') {
       text += '\n:\{\{subst:ffu|c\}\} ' + sub_m.comment + ' \~\~\~\~\n';
@theopolisme

This comment has been minimized.

Contributor

theopolisme replied Nov 10, 2013

Please sign in to comment.