diff options
author | simonbrandhof <simon.brandhof@gmail.com> | 2010-10-28 14:53:29 +0000 |
---|---|---|
committer | simonbrandhof <simon.brandhof@gmail.com> | 2010-10-28 14:53:29 +0000 |
commit | 11004fa74dbb211a6c5ec7bbff9d3d4e13e7964d (patch) | |
tree | 02373c3a4761ed47860c449f004bc3b7b80e359d /sonar-server/src/main/webapp/WEB-INF/app/models/dashboard.rb | |
parent | b918fe7c6647285b0584c5d1682102f9e8835c62 (diff) | |
download | sonarqube-11004fa74dbb211a6c5ec7bbff9d3d4e13e7964d.tar.gz sonarqube-11004fa74dbb211a6c5ec7bbff9d3d4e13e7964d.zip |
SONAR-1643 improve display of widgets to add + administrators can edit the default dashboard
Diffstat (limited to 'sonar-server/src/main/webapp/WEB-INF/app/models/dashboard.rb')
-rw-r--r-- | sonar-server/src/main/webapp/WEB-INF/app/models/dashboard.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/models/dashboard.rb b/sonar-server/src/main/webapp/WEB-INF/app/models/dashboard.rb index bbcc70ee061..11416159f18 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/models/dashboard.rb +++ b/sonar-server/src/main/webapp/WEB-INF/app/models/dashboard.rb @@ -37,7 +37,7 @@ class Dashboard < ActiveRecord::Base end
def editable_by?(user)
- (user && user_id==user.id) || (user_id.nil? && user.has_role?(:admin))
+ (user && self.user_id==user.id) || (user_id.nil? && user.has_role?(:admin))
end
def owner?(user)
|