]> git.openstreetmap.org Git - rails.git/blobdiff - app/models/user.rb
Reverting experimental stuff in r17121.
[rails.git] / app / models / user.rb
index 9d135a3a1ae4aa97e14202f9ea0bba1abd61d0e2..ae5b0b74f708b5b94ba5fc09242762b904c36955 100644 (file)
@@ -11,6 +11,9 @@ class User < ActiveRecord::Base
   has_many :preferences, :class_name => "UserPreference"
   has_many :changesets
 
+  has_many :client_applications
+  has_many :oauth_tokens, :class_name => "OauthToken", :order => "authorized_at desc", :include => [:client_application]
+
   validates_presence_of :email, :display_name
   validates_confirmation_of :email#, :message => ' addresses must match'
   validates_confirmation_of :pass_crypt#, :message => ' must match the confirmation password'