Add handlers and distance filtering