code: function removeDuplicateAttributes(attrs) {
      var attrsNames = [],
          res = [];
  
      _.forEach(attrs, function (attr) {
          if (attrsNames.indexOf(attr.name) === -1) {
              res.push(attr);
              attrsNames.push(attr.name);
          }
      });
  
      return res;
  }
docs: Removes duplicate attributes from the given list
  @param {Array} attrs
  @returns {Array}