Fixed an deprecation warning