projects
/
rails.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Use flex grid for diary index headings
[rails.git]
/
app
/
models
/
oauth2_application.rb
1
class Oauth2Application < Doorkeeper::Application
2
belongs_to :owner, :polymorphic => true
3
4
validate :allowed_scopes
5
6
private
7
8
def allowed_scopes
9
return if owner.administrator?
10
11
errors.add(:scopes) if scopes.any? { |scope| Oauth::PRIVILEGED_SCOPES.include?(scope) }
12
end
13
end