From 40f77be58425f8eb2a1afa09d543bd14c824cf9a Mon Sep 17 00:00:00 2001 From: karishmas6 Date: Mon, 30 Sep 2024 23:55:37 +0530 Subject: [PATCH] chore: prttier --- src/api/proxy.ts | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/api/proxy.ts b/src/api/proxy.ts index 670c3d4f..6246345d 100644 --- a/src/api/proxy.ts +++ b/src/api/proxy.ts @@ -1,15 +1,15 @@ import { default as axios } from "axios"; -export const sendProxyConfig = async (proxyConfig: {type: string, server: string, username:string, password: string}): Promise => { +export const sendProxyConfig = async (proxyConfig: { type: string, server: string, username: string, password: string }): Promise => { try { - const response = await axios.post(`http://localhost:8080/proxy/config`, proxyConfig); - if (response.status === 200) { - return response.data; - } else { - throw new Error(`Failed to submit proxy configuration. Try again.`); - } - } catch(error: any) { - console.log(error); - return false; + const response = await axios.post(`http://localhost:8080/proxy/config`, proxyConfig); + if (response.status === 200) { + return response.data; + } else { + throw new Error(`Failed to submit proxy configuration. Try again.`); + } + } catch (error: any) { + console.log(error); + return false; } - } \ No newline at end of file +} \ No newline at end of file