get static method
Implementation
static Future<dynamic> get(
{bool auth = true,
required String apiURL,
required String lang,
bool isPhone = false}) async {
try {
var response = await http
.get(Uri.parse(ApiClient.baseUrl + apiURL),
headers: ApiClient.headers(auth: auth, token: null, lang: lang))
.timeout(const Duration(seconds: timeOutDuration));
return ApiClient.processResponse(response);
} on SocketException {
throw FetchDataException('No Internet connection', '');
} on TimeoutException {
throw ApiNotRespondingException('API not responded in time', '');
}
}