Update to new API.

Change-Id: Ibe825155536f6551d3ada101aa32f08809c539fc