TP-22332 |changed axios inatance form axiois| Aman Singh
This commit is contained in:
2
App.tsx
2
App.tsx
@@ -9,7 +9,7 @@ import {
|
||||
PermissionsAndroid,
|
||||
Platform,
|
||||
StatusBar,
|
||||
type Permission
|
||||
type Permission,
|
||||
} from 'react-native';
|
||||
import { default as codePush, default as CodePush } from 'react-native-code-push';
|
||||
import { Provider } from 'react-redux';
|
||||
|
||||
@@ -304,7 +304,7 @@ const TrackingComponent: React.FC<ITrackingComponent> = ({ children }) => {
|
||||
{
|
||||
taskId: FOREGROUND_TASKS.DATA_SYNC_JOB,
|
||||
task: getSyncUrl,
|
||||
delay: 0.5 * MILLISECONDS_IN_A_MINUTE, // 30 minutes
|
||||
delay: 10 * MILLISECONDS_IN_A_MINUTE, // 30 minutes
|
||||
onLoop: true,
|
||||
}
|
||||
];
|
||||
|
||||
@@ -4,6 +4,7 @@ import axiosInstance, { API_STATUS_CODE } from '../components/utlis/apiHelper';
|
||||
import { getGzipData } from '../components/utlis/commonFunctions';
|
||||
import { logError } from '../components/utlis/errorUtils';
|
||||
import { sendAckToServer } from './deviceDataSyncService';
|
||||
import axios from 'axios';
|
||||
|
||||
|
||||
|
||||
@@ -17,7 +18,7 @@ export const calendarSyncService = async (params: {
|
||||
const data = JSON.stringify({ data: calendarEvents });
|
||||
getGzipData(data)
|
||||
.then((compressedData) => {
|
||||
axiosInstance
|
||||
axios
|
||||
.post(params.preSignedUrl, compressedData, {
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
|
||||
Reference in New Issue
Block a user