private void AddHeaderInfo(
     HeaderDescriptor descriptor,
     HttpHeaders.HeaderStoreItemInfo sourceInfo)
 {
     HttpHeaders.HeaderStoreItemInfo addHeaderToStore = this.CreateAndAddHeaderToStore(descriptor);
     if (descriptor.Parser == null)
     {
         addHeaderToStore.ParsedValue = HttpHeaders.CloneStringHeaderInfoValues(sourceInfo.ParsedValue);
     }
     else
     {
         addHeaderToStore.InvalidValue = HttpHeaders.CloneStringHeaderInfoValues(sourceInfo.InvalidValue);
         if (sourceInfo.ParsedValue == null)
         {
             return;
         }
         if (!(sourceInfo.ParsedValue is List <object> parsedValue))
         {
             HttpHeaders.CloneAndAddValue(addHeaderToStore, sourceInfo.ParsedValue);
         }
         else
         {
             foreach (object source in parsedValue)
             {
                 HttpHeaders.CloneAndAddValue(addHeaderToStore, source);
             }
         }
     }
 }