added profiles functionality