Skip to content

Commit

Permalink
removed unnecessary return if.
Browse files Browse the repository at this point in the history
  • Loading branch information
JonathanS223 committed Nov 30, 2023
1 parent 46635d9 commit 5f2a19f
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions app/models/creatorship.rb
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@ def check_banned
# disabled invitations.
def check_disallowed
return if approved? || pseud.nil?
# Prevents this error from appearing in addition to the error for banned or suspended users.
return if pseud&.user&.banned || pseud&.user&.suspended
return if pseud&.user&.preference&.allow_cocreator
errors.add(:base, ts("%{name} does not allow others to invite them to be a co-creator.",
name: pseud.byline))
Expand Down

0 comments on commit 5f2a19f

Please sign in to comment.