Adds error in the log