Fix exception when request.format is nil, which can happen when the request does not map to a defined Mime type (e.g., php).
Fix exception when request.format is nil, which can happen when the
request does not map to a defined Mime type (e.g., php).

benlangfeld/mobile-fu