Sinatra app converted to Rails exercise