better to do this inside DeprecatedFileOutputFormatWrapper?