Add required includes for map of callbacks.
Fix conflicting variable name.