InterviewSolution
Saved Bookmarks
| 1. |
How Do I Make The Trailing Slash Optional? |
|
Answer»
get '/foo/bar/?' do "HELLO World" The route matches "/foo/bar" and "/foo/bar/". Put a question mark after it: get '/foo/bar/?' do "Hello World" end The route matches "/foo/bar" and "/foo/bar/". |
|