adds deprication warning