]> git.openstreetmap.org Git - rails.git/blobdiff - app/models/user.rb
Made rubocop happy by formatting and minor syntax tweaks.
[rails.git] / app / models / user.rb
index 3d262fd254a4c14f782b12c7198b9889a4887e13..6fbf8eecbb31573121d0209cece0112edbc3cb7a 100644 (file)
@@ -26,9 +26,10 @@ class User < ActiveRecord::Base
 
   has_many :roles, :class_name => "UserRole"
 
-  has_many :issues
+  has_many :issues, :class_name => "Issue", :foreign_key => :reported_user_id
+  has_one :issue, :class_name => "Issue", :foreign_key => :updated_by
   has_many :issue_comments
-  
+
   has_many :reports
 
   scope :visible, -> { where(:status => %w(pending active confirmed)) }