Last active
September 2, 2019 06:24
-
-
Save haldarmahesh/a8ca7b4dcc03aba363a8da52d6c5fce5 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import logger from '../logSetup'; | |
processLoan(id: number, userId: number) { | |
try { | |
getLoanDeatilsById() | |
} catch(error) { | |
log.error(`Failed to do getLoanDetails with id ${id}, ignoring it and trying to getLoanDetailsByUserId`, error); | |
// good example: provide what failed, and how you are handling. | |
// e.g here on fail I am trying to call other function | |
getLoanDetailsByUserId(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment