From fbc390751a3aab27ed6808c040b71fc784920cbd Mon Sep 17 00:00:00 2001 From: krishnaglodha Date: Wed, 20 Nov 2024 02:41:18 +0530 Subject: [PATCH] fixed json.loads for result --- src/geoserverx/cli/cli.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/geoserverx/cli/cli.py b/src/geoserverx/cli/cli.py index b1cb10a..161fcbc 100644 --- a/src/geoserverx/cli/cli.py +++ b/src/geoserverx/cli/cli.py @@ -157,8 +157,8 @@ def update_workspace( result = client.update_workspace( current_name, UpdateWorkspaceInfo(name=new_name, isolated=isolated), - ).model_dump_json() - if json.loads(result)["code"] == 200: + ).model_dump() + if result['code'] == 200: typer.secho(result, fg=typer.colors.GREEN) else: typer.secho(result, fg=typer.colors.RED)