add param check for digestFile