Fix references
Feedback from Pepe

Some things was already fixed from Dima's feedback, other stuff I just
took notes of and will fix later.

583f9ac303ae3df141df36898520628a9a0ad30d