Added clapper logic