exception handling improvement!