Pass event through to function