repair select bug