<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def upload_content(self, synchronous=True, **kwargs):
 """Upload a file or files to the current repository. Here is an example of how to upload content:: with open('my_content.rpm') as content: repo.upload_content(files={'content': content}) This method accepts the same keyword arguments as Requests. As a result, the following examples can be adapted for use here: * `POST a Multipart-Encoded File`_ * `POST Multiple Multipart-Encoded Files`_ :param synchronous: What should happen if the server returns an HTTP 202 (accepted) status code? Wait for the task to complete if ``True``. Immediately return the server's response otherwise. :param kwargs: Arguments to pass to requests. :returns: The server's response, with all JSON decoded. :raises: ``requests.exceptions.HTTPError`` If the server responds with an HTTP 4XX or 5XX message. :raises nailgun.entities.APIResponseError: If the response has a status other than "success". .. _POST a Multipart-Encoded File: http://docs.python-requests.org/en/latest/user/quickstart/#post-a-multipart-encoded-file .. _POST Multiple Multipart-Encoded Files: http://docs.python-requests.org/en/latest/user/advanced/#post-multiple-multipart-encoded-files """

        kwargs = kwargs.copy()  # shadow the passed-in kwargs
        kwargs.update(self._server_config.get_client_kwargs())
        response = client.post(self.path('upload_content'), **kwargs)
        json = _handle_response(response, self._server_config, synchronous)
        if json['status'] != 'success':
            raise APIResponseError(
                # pylint:disable=no-member
                'Received error when uploading file {0} to repository {1}: {2}'
                .format(kwargs.get('files'), self.id, json)
            )
        return json