def _callback(_, result):
        '''Marshal the GAsyncReady callback into an (error, data) callback.'''
        try:
            bytes_data = EosCompanionAppService.finish_load_all_in_stream_to_bytes(
                result)
        except GLib.Error as error:
            callback(error, None)
            return

        callback(None, bytes_data)
    def _read_stream_callback(_, result):
        '''Callback once we have finished loading the stream to bytes.'''
        try:
            content_bytes = EosCompanionAppService.finish_load_all_in_stream_to_bytes(
                result)
        except GLib.Error as error:
            callback(error, None)
            return

        adjuster.render_async(content_type, content_bytes, version, query,
                              cache, cancellable, _content_adjusted_callback)