Updated code to reflect the proper error message in case of an unknown error apart from normal error .