Define user earlier so it can be used more