瀏覽代碼

[tasks] Fix bug in looking up user profile

Colin Powell 1 月之前
父節點
當前提交
4e37bc5ab9
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      vrobbler/apps/tasks/webhooks.py

+ 1 - 1
vrobbler/apps/tasks/webhooks.py

@@ -144,7 +144,7 @@ def emacs_webhook(request):
     if not user_id:
         user_id = 1
 
-    user_profile = UserProfile.objects.filter(user_id=user_id)
+    user_profile = UserProfile.objects.filter(user_id=user_id).first()
 
     scrobble = None
     if post_data.get("source_id"):