mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-23 23:58:31 -05:00
BUGFIX: edit category button should only be shown to staff members
This commit is contained in:
parent
c4cbf934d0
commit
5ec22cdd23
2 changed files with 2 additions and 2 deletions
|
@ -61,7 +61,7 @@ function buildCategoryRoute(filter, params) {
|
|||
|
||||
var opts = { category: model, filterMode: filterMode };
|
||||
opts.noSubcategories = params && params.no_subcategories;
|
||||
opts.canEditCategory = Discourse.User.current('staff');
|
||||
opts.canEditCategory = Discourse.User.currentProp('staff');
|
||||
this.controllerFor('navigationCategory').setProperties(opts);
|
||||
|
||||
return Discourse.TopicList.list(listFilter, params).then(function(list) {
|
||||
|
|
|
@ -50,7 +50,7 @@ Discourse.DiscoveryTopCategoryRoute = Discourse.Route.extend({
|
|||
|
||||
var opts = { category: model, filterMode: filterMode };
|
||||
opts.noSubcategories = noSubcategories;
|
||||
opts.canEditCategory = Discourse.User.current('staff');
|
||||
opts.canEditCategory = Discourse.User.currentProp('staff');
|
||||
this.controllerFor('navigationCategory').setProperties(opts);
|
||||
|
||||
return Discourse.TopList.find(filterMode).then(function(list) {
|
||||
|
|
Loading…
Reference in a new issue