consistent file object check