Update project with latest eslint rules

This commit is contained in:
Debajyoti Halder
2021-01-29 11:55:12 +05:30
parent da661f836e
commit 6106345e6d
49 changed files with 173 additions and 157 deletions
@@ -32,11 +32,11 @@ export const EscalationPolicy = ({ policyId }: Props) => {
const { value: users, loading, error } = useAsync(async () => {
const oncalls = await api.getOnCallByPolicyId(policyId);
const users = oncalls
const usersItem = oncalls
.sort((a, b) => a.escalation_level - b.escalation_level)
.map(oncall => oncall.user);
return users;
return usersItem;
});
if (error) {
@@ -52,11 +52,11 @@ export const TriggerDialog = ({
const [description, setDescription] = useState<string>('');
const [{ value, loading, error }, handleTriggerAlarm] = useAsyncFn(
async (description: string) =>
async (descriptions: string) =>
await api.triggerAlarm({
integrationKey,
source: window.location.toString(),
description,
description: descriptions,
userName,
}),
);