def _update_kwargs_item(self, item, key_name, position='<STR_LIT>'):
kwargs = self.server_kwargs<EOL>if key_name in self.server_kwargs:<EOL><INDENT>existing_items = kwargs[key_name]<EOL>if not isinstance(existing_items, (list, tuple)):<EOL><INDENT>existing_items = [existing_items]<EOL><DEDENT><DEDENT>else:<EOL><INDENT>existing_items = []<EOL><DEDENT>if position == '<STR_LIT>':<EOL><INDENT>kwargs[key_name] = [item] + existing_items<EOL><DEDENT>if position == '<STR_LIT>':<EOL><INDENT>kwargs[key_name] = existing_items + [item]<EOL><DEDENT>return kwargs<EOL>
Prepend a method to the existing preprocessing chain, add to self's kwargs and return.