fix deprecation error