Replace all error popups with one function.