@api_view(['GET'])
@mobile_view()
def my_user_info(request):
 return redirect('user-detail', username=request.user.username)

@ api_view ( [ 'GET' ] ) @ mobile_view ( ) def my_user_info ( request ) : return redirect ( 'user-detail' , username = request . user . username )
redirect to the currently-logged-in users info page .