Updated connector library to support custom referrer