var getKeywords = function getKeywords(article) {
  var keywords = [];
  var internalTag = article.internalTag,
      userDefinedTag = article.userDefinedTag,
      SponsorshipTag = article.SponsorshipTag,
      seoTag = article.seoTag;


  if (internalTag) {
    internalTag.map(function (item) {
      if (!keywords.includes(item)) {
        keywords.push(item);
      }
    });
  }

  if (userDefinedTag) {
    userDefinedTag.map(function (item) {
      if (!keywords.includes(item)) {
        keywords.push(item);
      }
    });
  }

  if (SponsorshipTag) {
    SponsorshipTag.map(function (item) {
      if (!keywords.includes(item)) {
        keywords.push(item);
      }
    });
  }

  if (seoTag) {
    seoTag.map(function (item) {
      if (!keywords.includes(item)) {
        keywords.push(item);
      }
    });
  }

  return keywords;
};

export default getKeywords;
