1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Check if path is /dev/null when checking if a file is in fact a file

This commit is contained in:
James Cammarata 2015-09-14 14:41:22 -04:00
parent 36b5858f51
commit 4f30db8ca5

View file

@ -125,7 +125,7 @@ class DataLoader():
def is_file(self, path):
path = self.path_dwim(path)
return os.path.isfile(path)
return os.path.isfile(path) or path == os.devnull
def is_directory(self, path):
path = self.path_dwim(path)