add file input check