Update to work for multiple output formats