Fix registration method.

Change-Id: I3262c6c8a1267eaa8d33634a9fbbc81f2d608de7