code: function (data) {
            //If a token is not configured, don't do anything.
            if (!token) {
              return;
            }
  
            //TODO we're injecting this here to resolve circular dependency issues.  Is this safe?
            var $location = $injector.get( '$location' );
  
            lastLog = new Date();
  
            var sentData = angular.extend({}, extra, data);
  
            if (includeCurrentUrl) {
              sentData.url = $location.absUrl()
            }
  
            if( includeTimestamp ) {
              sentData.timestamp = lastLog.toISOString();
            }
  
            //Loggly's API doesn't send us cross-domain headers, so we can't interact directly
            new Image().src = buildUrl(sentData);
          }
docs: Send the specified data to loggly as a json message.
  @param data