fix file exists test