added logout; added docs