Fix failing tests, and rename function

I updated everything, ran tests and fixed the failing ones.
I also took the liberty to rename a function :]