Fix warnings for missing reference