replaced object with function as placeholder for register callback