Fix replying in a topic that is uncategorized after allow_uncategorized_topics is set to false

This commit is contained in:
Neil Lalonde 2013-05-28 15:52:50 -04:00
parent 560fb15d8a
commit 264dd65410

View file

@ -174,7 +174,7 @@ Discourse.Composer = Discourse.Model.extend({
// reply is always required
if (this.get('replyLength') < Discourse.SiteSettings.min_post_length) return true;
if (!Discourse.SiteSettings.allow_uncategorized_topics && !this.get('categoryName')) return true;
if (this.get('editTitle') && !Discourse.SiteSettings.allow_uncategorized_topics && !this.get('categoryName')) return true;
return false;
}.property('loading', 'editTitle', 'titleLength', 'targetUsernames', 'replyLength', 'categoryName'),