1- # Support Ruby 2 and 3 API calls without importing
1+ # Support Python 2 and 3 API calls without importing
22# a 3rd party library
33try :
44 from urllib .request import Request as HTTPRequest
99
1010
1111class Request (object ):
12- """
12+ '''
1313 An object containing all the compiled information about the request made.
1414
1515 :var host: The host used for this API call
@@ -51,7 +51,7 @@ class Request(object):
5151
5252 :var app_version: The custom app version used for this request
5353 :vartype app_version: str
54- """
54+ '''
5555
5656 def __init__ (self , options ):
5757 self .http_request = None
@@ -86,10 +86,10 @@ def __initialize_headers(self):
8686
8787 # Determines the User Agent
8888 def __build_user_agent (self ):
89- user_agent = " amadeus-python/{0}" .format (self .client_version )
90- user_agent += " python/{0}" .format (self .language_version )
89+ user_agent = ' amadeus-python/{0}' .format (self .client_version )
90+ user_agent += ' python/{0}' .format (self .language_version )
9191 if self .app_id :
92- user_agent += " {0}/{1}" .format (self .app_id , self .app_version )
92+ user_agent += ' {0}/{1}' .format (self .app_id , self .app_version )
9393 return user_agent
9494
9595 # Builds up a HTTP Request objectm if not akready set
@@ -116,9 +116,9 @@ def _encoded_params(self):
116116
117117 # Builds up the full URL based on the scheme, host, path, and params
118118 def __full_url (self ):
119- full_url = " {0}://{1}{2}" .format (self .scheme , self .host , self .path )
119+ full_url = ' {0}://{1}{2}' .format (self .scheme , self .host , self .path )
120120 if (self .verb == 'GET' ):
121- full_url += " ?{0}" .format (self ._encoded_params ())
121+ full_url += ' ?{0}' .format (self ._encoded_params ())
122122 return full_url
123123
124124 # Adds an extra header if the verb is POST
0 commit comments