@@ -292,14 +292,13 @@ class Redirect(OAuthView, Mixin):
292292 an error.
293293 """
294294
295- def error_response (self , error , mimetype = 'application/json ' , status = 400 ,
295+ def error_response (self , error , mimetype = 'deprecated ' , status = 400 ,
296296 ** kwargs ):
297297 """
298298 Return an error response to the client with default status code of
299299 *400* stating the error as outlined in :rfc:`5.2`.
300300 """
301- return HttpResponse (json .dumps (error ), mimetype = mimetype ,
302- status = status , ** kwargs )
301+ return HttpResponse (json .dumps (error ), status = status , ** kwargs )
303302
304303 def get (self , request ):
305304 data = self .get_data (request )
@@ -457,14 +456,13 @@ def invalidate_access_token(self, access_token):
457456 """
458457 raise NotImplementedError
459458
460- def error_response (self , error , mimetype = 'application/json ' , status = 400 ,
459+ def error_response (self , error , mimetype = 'deprecated ' , status = 400 ,
461460 ** kwargs ):
462461 """
463462 Return an error response to the client with default status code of
464463 *400* stating the error as outlined in :rfc:`5.2`.
465464 """
466- return HttpResponse (json .dumps (error ), mimetype = mimetype ,
467- status = status , ** kwargs )
465+ return HttpResponse (json .dumps (error ), status = status , ** kwargs )
468466
469467 def access_token_response (self , access_token ):
470468 """
@@ -487,9 +485,7 @@ def access_token_response(self, access_token):
487485 except ObjectDoesNotExist :
488486 pass
489487
490- return HttpResponse (
491- json .dumps (response_data ), mimetype = 'application/json'
492- )
488+ return HttpResponse (json .dumps (response_data ))
493489
494490 def authorization_code (self , request , data , client ):
495491 """
0 commit comments