]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-3893 Removed syntax highlighting support in source REST API
authorJean-Baptiste Vilain <jean-baptiste.vilain@sonarsource.com>
Thu, 11 Apr 2013 14:49:55 +0000 (16:49 +0200)
committerJean-Baptiste Vilain <jean-baptiste.vilain@sonarsource.com>
Thu, 11 Apr 2013 14:49:55 +0000 (16:49 +0200)
sonar-core/src/main/java/org/sonar/core/source/jdbc/SnapshotDataDao.java
sonar-server/src/main/webapp/WEB-INF/app/models/snapshot_source.rb

index 45c2649758bdd663496e59ea63fcce8f605ec1da..0961b1d95e497f74ec9e3f7268000825fe5e85fb 100644 (file)
@@ -38,7 +38,7 @@ public class SnapshotDataDao implements BatchComponent, ServerComponent {
 
   public String selectSnapshotData(long snapshotId) {
 
-    SqlSession session = mybatis.openBatchSession();
+    SqlSession session = mybatis.openSession();
 
     try {
       SnapshotDataMapper mapper = session.getMapper(SnapshotDataMapper.class);
index 971717cd80cd9c8bca870ea0cc59d70a52ce4826..805f7ca8303fb305503e7c3c567b4eef8c5c47e8 100644 (file)
@@ -26,11 +26,7 @@ class SnapshotSource < ActiveRecord::Base
     from = (options[:from] ? options[:from].to_i - 1 : 0)
     to = (options[:to] ? options[:to].to_i - 2 : -1)
 
-    if (options[:color]=='true')
-      lines=syntax_highlighted_lines()
-    else
-      lines=lines(false)
-    end
+    lines=lines(false)
 
     json = {}
     lines[from..to].each_with_index do |line, id|