Fixed classcastexception