mirror of
https://github.com/Elysola/WebHooker.git
synced 2026-11-21 01:23:40 +00:00
fix(dispatch): honor stop on a matching fallback route
Once a fallback matches with stop enabled, skip later routes of the same group without affecting other groups. Cover multiple fallback routes in the group-isolation regression test.
This commit is contained in:
1 parent
a2ad4f699e
commit
3e44c0b659
2 files changed
+5
-3
No files matched your search
@@ -98,6 +98,7 @@ export async function dispatchEvent(
|
||||
if (route.fallback) {
|
||||
if (!regularMatched.has(scope) && matchRoute(route, event)) {
|
||||
tasks.push(processRoute(route));
|
||||
if (route.stop) stopped.add(scope);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user