Add a simpler version of is_regular_file.