diff --git a/osinaweb/osinacore/api/views.py b/osinaweb/osinacore/api/views.py index 726e5455..5b3b68bf 100644 --- a/osinaweb/osinacore/api/views.py +++ b/osinaweb/osinacore/api/views.py @@ -34,12 +34,6 @@ def authenticate_customer(request): user = authenticate(request, email=email, password=password) if user is not None: login(request, user) - response = JsonResponse({'success': True}) + return JsonResponse({'success': True}) else: - response = JsonResponse({'success': False, 'error': 'Invalid credentials'}) - - response["Access-Control-Allow-Origin"] = "https://osimenu.com" - response["Access-Control-Allow-Methods"] = "POST" - response["Access-Control-Allow-Headers"] = "Content-Type" - - return response + return JsonResponse({'success': False, 'error': 'Invalid credentials'}) \ No newline at end of file