From 8babf2e72a0e1af8a3ceaa7264eafeaa07d3e733 Mon Sep 17 00:00:00 2001 From: Farzam Mohammadi Date: Sun, 17 Jul 2022 15:49:18 -0400 Subject: [PATCH] Update author controller to return object on post --- app/api/controllers/author.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/api/controllers/author.py b/app/api/controllers/author.py index 4fd27b6..f6daf5e 100644 --- a/app/api/controllers/author.py +++ b/app/api/controllers/author.py @@ -38,8 +38,8 @@ def post(self): else: author = AuthorModel(name=name, profile_image=profile_image) author.save_to_db() - - return messages.AUTHOR_ADDED_SUCCESSFULLY, 200 + + return {"author": author.json()}, 200 @token_required @author_ns.doc(