From b05c93e26034ec0573b28d5676cf2306615cdea1 Mon Sep 17 00:00:00 2001 From: "Joshua M. Boniface" Date: Tue, 29 Jun 2021 18:31:56 -0400 Subject: [PATCH] Fix bad return from initialize call --- api-daemon/pvcapid/flaskapi.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/api-daemon/pvcapid/flaskapi.py b/api-daemon/pvcapid/flaskapi.py index 3d77fad0..f79fe1fb 100755 --- a/api-daemon/pvcapid/flaskapi.py +++ b/api-daemon/pvcapid/flaskapi.py @@ -304,10 +304,7 @@ class API_Initialize(Resource): else: overwrite_flag = False - if api_helper.initialize_cluster(overwrite=overwrite_flag): - return {"message": "Successfully initialized a new PVC cluster"}, 200 - else: - return {"message": "PVC cluster already initialized"}, 400 + return api_helper.initialize_cluster(overwrite=overwrite_flag) api.add_resource(API_Initialize, '/initialize')