mumuki-domain 6.6.0 → 6.6.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0fe12401571cc46abe567d3337c252fcbf0d9a974f37ad207b3d424086b95b7c
4
- data.tar.gz: dbc42a3ada461878dd43b5eb8dc14d0ec449349099b01a0b80dbf428f08edcdf
3
+ metadata.gz: 4ccf761c5b469ba65886d7d672d9008f1c6fe1dd8d46284f57c61bd95ed6ab6c
4
+ data.tar.gz: d2f88a156f28f15a26180ecb8744ec0d64bc55202eeff8167bec1843682b1667
5
5
  SHA512:
6
- metadata.gz: c228e0879bfc3c4e74013e21a5a8f5e5656e4c2da491b340fd89d24ab7bcc015735d42ad8ca66a2a54662a5ba0a15cf1c1a8ba53d145fbe6c8ce76da69815b81
7
- data.tar.gz: 6bf1b18815eda0d228a78c6471b6e6d786358dbd1e94ba951d480e830eb03163c83182022bcdd4eeec15fb99ba2e774cfd6947d3f0562ba9277182d297e4a9c3
6
+ metadata.gz: c5218f2f513870bca9ec4f0a2dd79fa368b7ce8ee67012cc8eca6a59010493964b5cb99db6d66a82ea5f7de52cd00801d757d8354f2ca061f1756f5799fda369
7
+ data.tar.gz: 115ac23ec78d20e9949dc85a218b9c702c5938e4259c1b4c217ac2b4ccfb5499562ef89175bcd768f4f37cb2775e273f6f30b65431f6cdf252c4a47bca06e9f9
@@ -99,7 +99,7 @@ class Organization < ApplicationRecord
99
99
  # ask for help in this organization
100
100
  #
101
101
  # Warning: this method does not strictly check user's permission
102
- def ask_for_help_enabled?(user)
102
+ def ask_for_help_enabled?(user = nil)
103
103
  report_issue_enabled? || community_link.present? || can_create_discussions?(user)
104
104
  end
105
105
 
@@ -108,8 +108,8 @@ class Organization < ApplicationRecord
108
108
  #
109
109
  # This is true only when this organization has a forum and the user
110
110
  # has the discusser pseudo-permission
111
- def can_create_discussions?(user)
112
- forum_enabled? && user.discusser_of?(self)
111
+ def can_create_discussions?(user = nil)
112
+ forum_enabled? && (!user || user.discusser_of?(self))
113
113
  end
114
114
 
115
115
  def import_from_resource_h!(resource_h)
@@ -1,5 +1,5 @@
1
1
  module Mumuki
2
2
  module Domain
3
- VERSION = '6.6.0'
3
+ VERSION = '6.6.1'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mumuki-domain
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.6.0
4
+ version: 6.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Franco Leonardo Bulgarelli