Fix for deprecation