Skip to content

Commit

Permalink
fix: spelling error (#1560)
Browse files Browse the repository at this point in the history
* fix: spelling error

* add launch.json config for ts debug

* chore: remove vscode configs about ts debug

---------

Co-authored-by: notaphplover <roberto.pintos.lopez@gmail.com>
  • Loading branch information
saifeiLee and notaphplover authored Oct 22, 2024
1 parent 50b06d4 commit db2ca06
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/planning/planner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import * as ERROR_MSGS from '../constants/error_msgs';
import { BindingTypeEnum, TargetTypeEnum } from '../constants/literal_types';
import * as METADATA_KEY from '../constants/metadata_keys';
import { interfaces } from '../interfaces/interfaces';
import { isStackOverflowExeption } from '../utils/exceptions';
import { isStackOverflowException } from '../utils/exceptions';
import { circularDependencyToException, getServiceIdentifierAsString, listMetadataForTarget, listRegisteredBindingsForServiceIdentifier } from '../utils/serialization';
import { Context } from './context';
import { Metadata } from './metadata';
Expand Down Expand Up @@ -236,7 +236,7 @@ function plan(
return context;
} catch (error) {
if (
isStackOverflowExeption(error)
isStackOverflowException(error)
) {
circularDependencyToException(context.plan.rootRequest);
}
Expand Down
4 changes: 2 additions & 2 deletions src/utils/exceptions.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as ERROR_MSGS from '../constants/error_msgs';

export function isStackOverflowExeption(error: unknown): error is RangeError {
export function isStackOverflowException(error: unknown): error is RangeError {
return (
error instanceof RangeError ||
(error as Error).message === ERROR_MSGS.STACK_OVERFLOW
Expand All @@ -11,7 +11,7 @@ export const tryAndThrowErrorIfStackOverflow = <T>(fn: () => T, errorCallback: (
try {
return fn();
} catch (error) {
if (isStackOverflowExeption(error)) {
if (isStackOverflowException(error)) {
error = errorCallback();
}
throw error;
Expand Down

0 comments on commit db2ca06

Please sign in to comment.