added code for profile stuff