Fixing deprecation warning.