Improve deprecation warning