fix for deprecated function call