Fix a bug which prevented output generation