added registerDeviceForPush method