fixed castexception