Fix deprecated function and more fallback