Set up handler in core