ClassCastException instead of null