summaryrefslogtreecommitdiff
path: root/.rubocop.yml
diff options
context:
space:
mode:
authorRobert Speicher <robert@gitlab.com>2016-06-01 17:36:42 +0000
committerRobert Speicher <robert@gitlab.com>2016-06-01 17:36:42 +0000
commit164fc34eb2268aff648b688a782ac1ffdaf31c42 (patch)
treee86bee82c2bf25e780c31c4ecb1ab29792a0518c /.rubocop.yml
parent4621531a40ff46650e89b62b4e60933673ef904a (diff)
parent0319d5b63233e132672b836409b8a073cab05d10 (diff)
downloadgitlab-ce-164fc34eb2268aff648b688a782ac1ffdaf31c42.tar.gz
Merge branch 'rubocop/enable-style-for-cop' into 'master'
Enable Style/For rubocop cop > Do not use `for`, unless you know exactly why. Most of the time iterators should be used instead. `for` is implemented in terms of `each` (so you're adding a level of indirection), but with a twist - `for` doesn't introduce a new scope (unlike `each`) and variables defined in its block will be visible outside it. See #17478 See merge request !4397
Diffstat (limited to '.rubocop.yml')
-rw-r--r--.rubocop.yml2
1 files changed, 1 insertions, 1 deletions
diff --git a/.rubocop.yml b/.rubocop.yml
index 9275f9537d5..d9c253ba1ef 100644
--- a/.rubocop.yml
+++ b/.rubocop.yml
@@ -247,7 +247,7 @@ Style/FlipFlop:
# Checks use of for or each in multiline loops.
Style/For:
- Enabled: false
+ Enabled: true
# Enforce the use of Kernel#sprintf, Kernel#format or String#%.
Style/FormatString: