diff --git a/app/controllers/games_controller.rb b/app/controllers/games_controller.rb index 2a2439226..76e15f9e2 100644 --- a/app/controllers/games_controller.rb +++ b/app/controllers/games_controller.rb @@ -426,12 +426,12 @@ class GamesController < ApplicationController game_code = GameCode.where(:game_id => @game.try(:id), :path => path).first if game_code.present? content = game_code.try(:new_code) - @content = if @myshixun.mirror_name.select{|a| a.include?("MachineLearning") || a.include?("Python")}.present? && content.present? - content.gsub(/\t/, ' ') - else - content - end - update_file_content(@content, @myshixun.repo_path, path, current_user.mail, current_user.full_name, "game passed reset") + # @content = if @myshixun.mirror_name.select{|a| a.include?("MachineLearning") || a.include?("Python")}.present? && content.present? + # content.gsub(/\t/, ' ') + # else + # content + # end + update_file_content(content, @myshixun.repo_path, path, current_user.mail, current_user.full_name, "game passed reset") else tip_exception("代码重置失败,代码为空") end