Replace deprecated methods
Assigning this to 2.6.1, doesn't need to be done for the next release
Undoing my last action, didn't initially notice that there was a patch already submitted.
Here is a patch only for one of the errors. Other i'll upload some time later.