fixed some deprecation warnings