Add error handling in UI side.