diff options
author | Robert Speicher <robert@gitlab.com> | 2016-07-08 16:34:53 +0000 |
---|---|---|
committer | Robert Speicher <robert@gitlab.com> | 2016-07-08 16:34:53 +0000 |
commit | 989a9607e6bf63888b8856eb58a1c8e3e65e3604 (patch) | |
tree | cf77897da1e2283f74e178b373c69e2098c3a0b3 /app/controllers | |
parent | 140a706e96220ef1dab9ba220d86531ca5d46058 (diff) | |
parent | 4c388fb86500a2691c7b584ffafcbac18d643cab (diff) | |
download | gitlab-ce-989a9607e6bf63888b8856eb58a1c8e3e65e3604.tar.gz |
Merge branch 'rubocop/enable-identical-conditional-branches-cop' into 'master'
Enable Style/IdenticalConditionalBranches Rubocop cop
## What does this MR do?
This MR enables Rubocop cop that checks for identical lines at the end of each branch of a conditional statement.
Examples:
```ruby
@bad
if condition
do_x
do_z
else
do_y
do_z
end
@good
if condition
do_x
else
do_y
end
do_z
```
## What are the relevant issue numbers?
#17478
See merge request !5011
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/projects_controller.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 12e0d5a8413..1803aa8eab4 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -53,11 +53,11 @@ class ProjectsController < Projects::ApplicationController notice: "Project '#{@project.name}' was successfully updated." ) end - format.js else format.html { render 'edit' } - format.js end + + format.js end end |