Add fail handler and notification

I need a way to be notified on failure, so I added another postNotification to didFailWithError. Thank you.