Skip to content

Commit

Permalink
style: code prettier (#1480)
Browse files Browse the repository at this point in the history
  • Loading branch information
Linkontoask committed Jul 21, 2022
1 parent 0cc066b commit 583e77d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/router/src/navigationGuards.ts
Expand Up @@ -137,7 +137,7 @@ export function guardToPromiseFn(
const next: NavigationGuardNext = (
valid?: boolean | RouteLocationRaw | NavigationGuardNextCallback | Error
) => {
if (valid === false)
if (valid === false) {
reject(
createRouterError<NavigationFailure>(
ErrorTypes.NAVIGATION_ABORTED,
Expand All @@ -147,7 +147,7 @@ export function guardToPromiseFn(
}
)
)
else if (valid instanceof Error) {
} else if (valid instanceof Error) {
reject(valid)
} else if (isRouteLocation(valid)) {
reject(
Expand All @@ -165,8 +165,9 @@ export function guardToPromiseFn(
// since enterCallbackArray is truthy, both record and name also are
record!.enterCallbacks[name!] === enterCallbackArray &&
typeof valid === 'function'
)
) {
enterCallbackArray.push(valid)
}
resolve()
}
}
Expand Down

0 comments on commit 583e77d

Please sign in to comment.