added error listeners