Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def __write_file(self, file, link, timestamp):
"""
write entry to org file (omit replacement of spaces in file names)
"""
output = OrgFormat.link(link="file:" + link, description=file, replacespaces=False)
properties = None
if not self._args.omit_drawers:
# we need optional data for hashing due it can be, that more
# than one file have the same timestamp
properties = OrgProperties(data_for_hashing=output)
self._writer.write_org_subitem(timestamp=timestamp,
output=output,
properties=properties)