Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

change use ":" as delimiter in whitelist

  • Loading branch information...
commit 21541bd8848c6e9ae61a2e13676c987f3af06ba0 1 parent f098b93
@satococoa authored
Showing with 2 additions and 2 deletions.
  1. +1 −1  app/models/user.rb
  2. +1 −1  spec/models/user_spec.rb
View
2  app/models/user.rb
@@ -36,7 +36,7 @@ def member?(org)
def whitelisted?(whitelist)
unless whitelist.blank?
- uid_list = whitelist.to_s.split(',')
+ uid_list = whitelist.to_s.split(':')
return true if uid_list.include?(uid)
end
false
View
2  spec/models/user_spec.rb
@@ -39,7 +39,7 @@
it { should be_false }
end
context 'whitelistにuidが含まれるとき' do
- let(:whitelist) { "xxxxxx,#{user.uid}" }
+ let(:whitelist) { "xxxxxx:#{user.uid}" }
it { should be_true }
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.