refs #31 - fixes tpm file writing op