jonthornton / MTAPI

JSON proxy server for the MTA's realtime New York City subway feed
281 stars 84 forks source link

Feature: upper case route if route is non-numeric #12

Closed blakeyoder closed 5 years ago

blakeyoder commented 6 years ago

What are your thoughts on having the route be upper cased for all non-numeric routes.

/by-route/G and /by-route/g would return the same data set. As is, the lower cased route returns an empty list.

jonthornton commented 6 years ago

I like that suggestion - returning an empty list is a pretty confusing response. What do you think of canonicalizing on either upper or lower case, and having the other case return 301 redirects to the canonical URL?