Check for nil function being passed to #Once to prevent an unnecessary listener to be added to remove it.