Fixed deprication errors