Thank you for your reply!
Sorry, I didn’t press enter enough times after the first statement. (So I already entered the second statement while the first one was being executed). However, when I do press enter enough times, I run into this error:
So I changed it to this:
UserAnonymizer.make_anonymous(user, nil, {anonymize_ip: "0.0.0.0"})
And now it works!