fixed first time login and subsequent profile save