Module: TrimPathSeparators

Defined in:
app/lib/trim_path_separators.rb

Constant Summary collapse

TRIM_PATH_SEPARATOR_REGEXP =
/(^#{File::SEPARATOR})|(#{File::SEPARATOR}$)/

Instance Method Summary collapse

Instance Method Details

#trim_path_separators ⇒ Object



4
5
6
# File 'app/lib/trim_path_separators.rb', line 4

def trim_path_separators
  gsub(TRIM_PATH_SEPARATOR_REGEXP, "")
end