git-hulk commented on code in PR #337:
URL: 
https://github.com/apache/kvrocks-controller/pull/337#discussion_r2278821835


##########
webui/src/app/lib/api.ts:
##########
@@ -56,7 +56,7 @@ export async function createNamespace(name: string): 
Promise<string> {
 export async function deleteNamespace(name: string): Promise<string> {
     try {
         const { data: responseData } = await 
axios.delete(`${apiHost}/namespaces/${name}`);
-        if (responseData.data == null) {
+        if (responseData == null || responseData.data == null || 
responseData.data === "ok") {

Review Comment:
   @Jitmisra could you add a method to avoid the duplicate code?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to