fixed deprecation warning