mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 08:09:33 +08:00
parent
d78ed3159d
commit
c1769b0ec5
|
@ -19,12 +19,12 @@ export default Ember.Component.extend({
|
|||
@computed("model.visibility_level", "model.public_admission")
|
||||
disableMembershipRequestSetting(visibility_level, publicAdmission) {
|
||||
visibility_level = parseInt(visibility_level);
|
||||
return ![0, 1].includes(visibility_level) || publicAdmission;
|
||||
return publicAdmission || visibility_level > 1;
|
||||
},
|
||||
|
||||
@computed("model.visibility_level", "model.allow_membership_requests")
|
||||
disablePublicSetting(visibility_level, allowMembershipRequests) {
|
||||
visibility_level = parseInt(visibility_level);
|
||||
return ![0, 1].includes(visibility_level) || allowMembershipRequests;
|
||||
return allowMembershipRequests || visibility_level > 1;
|
||||
}
|
||||
});
|
||||
|
|
|
@ -139,7 +139,7 @@ const Group = RestModel.extend({
|
|||
|
||||
@computed("visibility_level")
|
||||
isPrivate(visibilityLevel) {
|
||||
return ![0, 1].includes(visibilityLevel);
|
||||
return visibility_level > 1;
|
||||
},
|
||||
|
||||
@observes("isPrivate", "canEveryoneMention")
|
||||
|
|
Loading…
Reference in New Issue
Block a user