diff --git a/backend/app/views_directory/postviews.py b/backend/app/views_directory/postviews.py index e2eb9176..b99beaa5 100644 --- a/backend/app/views_directory/postviews.py +++ b/backend/app/views_directory/postviews.py @@ -90,7 +90,7 @@ def create_post(request): post = Post.objects.create( title=title, description=description, - author=request.user.username, + author=request.user, tags=tags, # Directly assign the list of tags created_at=timezone.now() )