Added sasscache
Added type to emails

Closes #38
Purged unused functions
Added Session Handler
Optimize and clean code