if (options.files) {
    headers['Content-Type'] = 'multipart/form-data';
  } else if (!headers['Content-Type'] && method !== 'GET' && Object.keys(params).length > 0) {
    headers['Content-Type'] = 'application/json';    
  }