Created
December 2, 2010 01:32
-
-
Save tav/724584 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @register_service('places.json', [json]) | |
| def places_json( | |
| ctx, north=None, east=None, south=None, west=None, bounds=None, | |
| id=0, deadline=None, soon=None, verified=None, auto=None, | |
| zoom=None, order=None, via=None | |
| ): | |
| if bounds: | |
| (south, west), (north, east) = [ | |
| [float(_part) for _part in part.split(', ')] | |
| for part in bounds[2:-2].split('), (') | |
| ] | |
| else: | |
| north, east, south, west = map(float, [north, east, south, west]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment