corrected the parameters for the AddUrlSegment method