RED-8623: use some instead of reduce.

This commit is contained in:
Nicoleta Panaghiu 2024-03-06 15:34:17 +02:00
parent 52467b9dde
commit 1b93d38872

View File

@ -3,5 +3,5 @@ import { NO_CHECK_PAGES } from '@utils/constants';
import { Router } from '@angular/router';
export function filterEventsOnPages(router: Router) {
return filter(() => !NO_CHECK_PAGES.reduce((acc, route) => acc || router.url.includes(route), false));
return filter(() => !NO_CHECK_PAGES.some(route => router.url.includes(route)));
}