code: public static Map<String, VariantSet> concatVariants(Map<String, VariantSet> variantSet1,
  			Map<String, VariantSet> variantSet2) {
  
  		Map<String, VariantSet> result = new HashMap<>();
  		if (!isEmpty(variantSet1) && isEmpty(variantSet2)) {
  			result.putAll(variantSet1);
  		} else if (isEmpty(variantSet1) && !isEmpty(variantSet2)) {
  			result.putAll(variantSet2);
  		} else if (!isEmpty(variantSet1) && !isEmpty(variantSet2)) {
  
  			Set<String> keySet = new HashSet<>();
  			keySet.addAll(variantSet1.keySet());
  			keySet.addAll(variantSet2.keySet());
  			for (String variantType : keySet) {
  				VariantSet variants1 = variantSet1.get(variantType);
  				VariantSet variants2 = variantSet2.get(variantType);
  				Set<String> variants = new HashSet<>();
  				String defaultVariant = null;
  
  				if (variants1 != null && variants2 != null && !variants1.hasSameDefaultVariant(variants2)) {
  					throw new BundlingProcessException("For the variant type '" + variantType
  							+ "', the variant sets defined in your bundles don't have the same default value.");
  				}
  
  				if (variants1 != null) {
  					variants.addAll(variants1);
  					defaultVariant = variants1.getDefaultVariant();
  				}
  				if (variants2 != null) {
  					variants.addAll(variants2);
  					defaultVariant = variants2.getDefaultVariant();
  				}
  
  				VariantSet variantSet = new VariantSet(variantType, defaultVariant, variants);
  				result.put(variantType, variantSet);
  			}
  		}
  
  		return result;
  	}
docs: Concatenates 2 map of variant sets.
  
  @param variantSet1
  the first map
  @param variantSet2
  the second map
  @return the concatenated variant map