@exc.on_http_error(exc.GitlabUpdateError)<EOL><INDENT>def update(self, file_path, new_data={}, **kwargs):<DEDENT>
data = new_data.copy()<EOL>file_path = file_path.replace('<STR_LIT:/>', '<STR_LIT>')<EOL>data['<STR_LIT>'] = file_path<EOL>path = '<STR_LIT>' % (self.path, file_path)<EOL>self._check_missing_update_attrs(data)<EOL>return self.gitlab.http_put(path, post_data=data, **kwargs)<EOL>
Update an object on the server.

        Args:
            id: ID of the object to update (can be None if not required)
            new_data: the update data for the object
            **kwargs: Extra options to send to the server (e.g. sudo)

        Returns:
            dict: The new object data (*not* a RESTObject)

        Raises:
            GitlabAuthenticationError: If authentication is not correct
            GitlabUpdateError: If the server cannot perform the request