Fix script reply execution from event loop