Fix all Rails/FilePath rubocop issues

This commit is contained in:
Bertocq
2017-07-10 23:08:02 +02:00
parent 3a54713ed0
commit 5a358bce17
3 changed files with 2 additions and 8 deletions

View File

@@ -6,7 +6,7 @@ class SandboxController < ApplicationController
helper_method(:namespace)
def index
@templates = Dir.glob(Rails.root.join('app/views/sandbox/*.html.erb').to_s).map do |filename|
@templates = Dir.glob(Rails.root.join('app', 'views', 'sandbox', '*.html.erb').to_s).map do |filename|
filename = File.basename(filename, File.extname(filename))
filename unless filename.starts_with?('_') || filename == 'index.html'
end.compact