import axios from 'axios'; import BridgeFunction from './bridgeFunction'; import { MiniAppError, MiniAppErrorType } from '../miniAppError'; class GetIpAddress extends BridgeFunction { name = 'getIpAddress'; protected async executeFunction() { await axios.get('/network').then((res) => { if (res?.data) { return this.cbHandler?.success(res?.data); } else { throw new MiniAppError(MiniAppErrorType.noValueFound); } }); } } export default GetIpAddress;