Fix minor deprecation warning