Fixed error listener syntax