Move all emails into emails class

Also put the $from operator back into the function call, I'll need that.
Bug fixes + account rep lookup