repalce limit param of -1 with null
This commit is contained in:
1 parent
975e6d61b5
commit
d76f02ba51
1 file changed
+2
-3
@@ -29,7 +29,7 @@ const Incidents = () => {
|
|||||||
const res = await networkService.getMonitorsByTeamId({
|
const res = await networkService.getMonitorsByTeamId({
|
||||||
authToken: authState.authToken,
|
authToken: authState.authToken,
|
||||||
teamId: authState.user.teamId,
|
teamId: authState.user.teamId,
|
||||||
limit: -1,
|
limit: null,
|
||||||
types: null,
|
types: null,
|
||||||
status: null,
|
status: null,
|
||||||
checkOrder: null,
|
checkOrder: null,
|
||||||
@@ -40,7 +40,6 @@ const Incidents = () => {
|
|||||||
field: null,
|
field: null,
|
||||||
order: null,
|
order: null,
|
||||||
});
|
});
|
||||||
// Reduce to a lookup object for 0(1) lookup
|
|
||||||
if (res?.data?.data?.monitors?.length > 0) {
|
if (res?.data?.data?.monitors?.length > 0) {
|
||||||
const monitorLookup = res.data.data.monitors.reduce((acc, monitor) => {
|
const monitorLookup = res.data.data.monitors.reduce((acc, monitor) => {
|
||||||
acc[monitor._id] = monitor;
|
acc[monitor._id] = monitor;
|
||||||
@@ -56,7 +55,7 @@ const Incidents = () => {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
fetchMonitors();
|
fetchMonitors();
|
||||||
}, [authState]);
|
}, [authState, monitorId]);
|
||||||
|
|
||||||
useEffect(() => {}, [monitors]);
|
useEffect(() => {}, [monitors]);
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user