remove unused var and suppress warnings unchecked