]> source.dussan.org Git - redmine.git/commitdiff
code cleanup: rubocop: fix Style/RedundantBegin in lib/redmine/scm/adapters/git_adapt...
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Tue, 8 Oct 2019 14:09:40 +0000 (14:09 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Tue, 8 Oct 2019 14:09:40 +0000 (14:09 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@18626 e93f8b46-1217-0410-a6f0-8f06a7374b81

.rubocop_todo.yml
lib/redmine/scm/adapters/git_adapter.rb

index 987af4da71f948b821bc16417b369f3e9e8bd7a7..3044bda6ce1feef0c3e9484850d36e0413d39814 100644 (file)
@@ -1388,11 +1388,6 @@ Style/RaiseArgs:
     - 'lib/redmine/scm/adapters/filesystem_adapter.rb'
     - 'lib/redmine/sort_criteria.rb'
 
-# Cop supports --auto-correct.
-Style/RedundantBegin:
-  Exclude:
-    - 'lib/redmine/scm/adapters/git_adapter.rb'
-
 # Cop supports --auto-correct.
 Style/RedundantConditional:
   Exclude:
index 22389bbbec6058bfd83c1147644c76a2e2322a74..1c0c9869903658a759cca1e35471ca832e48c983 100644 (file)
@@ -70,11 +70,9 @@ module Redmine
         end
 
         def info
-          begin
-            Info.new(:root_url => url, :lastrev => lastrev('',nil))
-          rescue
-            nil
-          end
+          Info.new(:root_url => url, :lastrev => lastrev('',nil))
+        rescue
+          nil
         end
 
         def branches