Work properly with sessions
Update docs