           @redirect returnTo
         else @redirectToTeam person
       else
-        @redirect '/people/' + person.id() + '/edit'
+        @redirect '/people/' + person.toParam() + '/edit'
     else
       @errors = error
       @person = new Person(@req.body)


get '/me', ->
  if @currentPerson?
    @redirect "/people/#{@currentPerson.id()}/edit"
  else
    @redirectToLogin()


          redirectToTeam: (person, alternatePath) ->
            Team.first { 'members._id': person._id }, (error, team) =>
              if team?
                @redirect '/teams/' + team.toParam()
              else
                @redirect (alternatePath or '/')
          redirectToLogin: ->
