Noosfero/noosfero

View on GitHub
plugins/require_auth_to_comment/public/hide_comment_form.js

Summary

Maintainability
A
0 mins
Test Coverage
(function($) {
  $(window).bind('userDataLoaded', function(event, data) {
    if (data.login || $('meta[name="profile.allow_unauthenticated_comments"]').length > 0) {
      $('.post-comment-button, .page-comment-form, .comment-footer, .display-comment-form').livequery(function() {
        $(this).show();
      });
    }
  });
})(jQuery);