Module: Rack::Mount::Utils

Defined in:
lib/sockjs/duck-punch-rack-mount.rb

Class Method Summary collapse

Class Method Details

.normalize_path(path) ⇒ Object



4
5
6
7
8
9
10
# File 'lib/sockjs/duck-punch-rack-mount.rb', line 4

def normalize_path(path)
  path = "/#{path}" unless path[0] = ?/
  path = '/' if path == ''
  path

  return path
end