MCPcopy Index your code
hub / github.com/googlemaps/google-maps-services-python / normalize_for_urlencode

Function normalize_for_urlencode

googlemaps/client.py:523–531  ·  view source on GitHub ↗

(Python 2) Converts the value to a `str` (raw bytes).

(value)

Source from the content-addressed store, hash-verified

521 # raised here, and caught below.
522
523 def normalize_for_urlencode(value):
524 """(Python 2) Converts the value to a `str` (raw bytes)."""
525 if isinstance(value, unicode):
526 return value.encode('utf8')
527
528 if isinstance(value, str):
529 return value
530
531 return normalize_for_urlencode(str(value))
532
533except NameError:
534 def normalize_for_urlencode(value):

Callers 1

urlencode_paramsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected