small changes to avoid deprecation warnings