          {'foo': 'abc', 'bar': 'def'},
          {'foo': 'hij', 'bar': 'klm'}
      ]
      """
      Dict = type(dictionary)
      ret = {}
      regex = re.compile(r'^%s\[([0-9]+)\](.*)$' % re.escape(prefix))
      for field, value in dictionary.items():
          match = regex.match(field)
          if not match:
 
</s> remove             ret[index] = Dict({key: value})
 </s> add             ret[index] = MultiValueDict({key: [value]})
          {'foo': 'abc', 'bar': 'def'},
          {'foo': 'hij', 'bar': 'klm'}
      ]
      """

      ret = {}
      regex = re.compile(r'^%s\[([0-9]+)\](.*)$' % re.escape(prefix))
      for field, value in dictionary.items():
          match = regex.match(field)
          if not match:
keep keep keep keep replace keep keep keep keep keep
 Tests & fixes for list serialization 
rest_framework/utils/html.py