added registerCallbackForName