diff --git a/app/helpers/shixuns_helper.rb b/app/helpers/shixuns_helper.rb index 74c1a0510..d849053ca 100644 --- a/app/helpers/shixuns_helper.rb +++ b/app/helpers/shixuns_helper.rb @@ -124,12 +124,9 @@ module ShixunsHelper if script.present? source_class_name = [] challenge_program_name = [] - logger.info("########-----shixun.challenges.map(&:exec_path):#{shixun.challenges.map(&:exec_path)}") shixun.challenges.map(&:exec_path).each do |exec_path| challenge_program_name << "\"#{exec_path}\"" - logger.info("----mirror_name: #{shixun.main_mirror_name.try(:first)}") - logger.info("----mirror_name1: #{shixun.main_mirror_name.try(:first) == "Java"}") - if shixun.main_mirror_name.try(:first) == "Java" + if shixun.main_mirror_name == "Java" if exec_path.nil? || exec_path.split("src/")[1].nil? source = "\"\"" else @@ -146,7 +143,6 @@ module ShixunsHelper source_class_name << source if source.present? end end - logger.info("######source_class_name: #{source_class_name}") script = if script.include?("sourceClassName") && script.include?("challengeProgramName") script.gsub(/challengeProgramNames=\(.*\)/,"challengeProgramNames=\(#{challenge_program_name.reject(&:blank?).join(" ")}\)").gsub(/sourceClassNames=\(.*\)/, "sourceClassNames=\(#{source_class_name.reject(&:blank?).join(" ")}\)") else