Generate correct route when :format segment is mandatory (fixing #57)

The issue was that in `get 'people.:format'` the format segment is separated by `.`. not `/`.

Fixing https://github.com/enriclluelles/route_translator/issues/57.

But my fix only works for `.:format` segment. It will not work for other segment separated by dot! e.g. `/people.:something`.