Allow passing of fid as well as filename.

This should be backwards compatible with old usage.

Signed-off-by: David Brainard <brainard@psych.upenn.edu>
Fix typo in previous modification.

Signed-off-by: David Brainard <brainard@psych.upenn.edu>