Fixes for api changes