fix metric bug