Fixes error with exception.