Fixed some deprecations.