#10 -- Added check to ensure that callback is available when error occurs.