removed overlay and group for scan function if it is not necessary