]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-2488 Fix conversion to integer for comment ID
authorFabrice Bellingard <bellingard@gmail.com>
Wed, 8 Jun 2011 08:14:17 +0000 (10:14 +0200)
committerFabrice Bellingard <bellingard@gmail.com>
Wed, 8 Jun 2011 08:14:17 +0000 (10:14 +0200)
sonar-server/src/main/webapp/WEB-INF/app/models/review.rb

index e44ce280a5575a2b430e877006fb7d03fb96cb88..638270e147695c63d8f2c5a8da829d5b61cc3d5a 100644 (file)
@@ -261,7 +261,7 @@ class Review < ActiveRecord::Base
       xml.comments do
         review_comments.each do |comment|
           xml.comment do
-            xml.id(comment.id)
+            xml.id(comment.id.to_i)
             xml.author(comment.user.login)
             xml.updatedAt(Api::Utils.format_datetime(comment.updated_at))
             if convert_markdown 
@@ -296,7 +296,7 @@ class Review < ActiveRecord::Base
     comments = []
     review_comments.each do |comment|
       comments << {
-        'id' => comment.id,
+        'id' => comment.id.to_i,
         'author' => comment.user.login,
         'updatedAt' => Api::Utils.format_datetime(comment.updated_at),
         'text' => convert_markdown ? comment.html_text : comment.plain_text