Skip to content

Commit

Permalink
Merge pull request #29 from TeamHive/feat/sso-exception
Browse files Browse the repository at this point in the history
feat(exception): adds sso-exception
  • Loading branch information
jpinkster authored Jul 25, 2019
2 parents 5e28fdc + f56e545 commit a59defb
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/modules/exceptions/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@ export * from './passive.exception';
export * from './redirect.exception';
export * from './redis.exception';
export * from './sql.exception';
export * from './sso.exception';
export * from './unauthorized.exception';
export * from './validation.exception';
12 changes: 12 additions & 0 deletions src/modules/exceptions/sso.exception.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { HttpStatus } from '@nestjs/common';
import { LoggedException } from './logged.exception';

export class SsoException extends LoggedException {
constructor(error?: Error, customMessage?: string) {
super(
customMessage || 'Internal server error with SSO',
HttpStatus.INTERNAL_SERVER_ERROR,
error
);
}
}

0 comments on commit a59defb

Please sign in to comment.