From 588a039a2921bcadd1806539ecd4c40efc5057ec Mon Sep 17 00:00:00 2001 From: Meoyoug Date: Thu, 30 May 2024 23:35:03 +0900 Subject: [PATCH] =?UTF-8?q?Fix:=20=EC=86=8C=EC=85=9C=20=EB=A1=9C=EA=B7=B8?= =?UTF-8?q?=EC=9D=B8=20=EC=8B=9C=20user=20create=20=EB=B6=80=EB=B6=84=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/user/views.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/apps/user/views.py b/apps/user/views.py index de69742..2e2d805 100644 --- a/apps/user/views.py +++ b/apps/user/views.py @@ -267,10 +267,9 @@ def create_user( image_response = urlopen(profile_img_url) image_content = image_response.read() profile_image = ContentFile(image_content, name=f"{provider_info['name']}-profile-{uuid4_generator(8)}.jpg") + user = Account.objects.create(email=email, nickname=nickname, profile_img=profile_image) else: - profile_image = None - user = Account.objects.create(email=email, nickname=nickname, profile_img=profile_image) - user.set_unusable_password() + user = Account.objects.create(email=email, nickname=nickname) user.save() return user