Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -659,3 +659,18 @@ def create_directory(self, directory_name, **kwargs):
kwargs.setdefault('merge_span', True)
directory.create_directory(**kwargs)
return directory # type: ignore

@distributed_trace
def delete_directory(self, directory_name, **kwargs):
# type: (str, Any) -> None
"""Marks the directory for deletion. The directory is
later deleted during garbage collection.

:param str directory_name:
The name of the directory.
:keyword int timeout:
The timeout parameter is expressed in seconds.
:rtype: None
"""
directory = self.get_directory_client(directory_name)
directory.delete_directory(**kwargs)
Original file line number Diff line number Diff line change
Expand Up @@ -538,3 +538,18 @@ async def create_directory(self, directory_name, **kwargs):
kwargs.setdefault('merge_span', True)
await directory.create_directory(**kwargs)
return directory # type: ignore

@distributed_trace

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there is an async decorator

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

async def delete_directory(self, directory_name, **kwargs):
# type: (str, Any) -> None
"""Marks the directory for deletion. The directory is
later deleted during garbage collection.

:param str directory_name:
The name of the directory.
:keyword int timeout:
The timeout parameter is expressed in seconds.
:rtype: None
"""
directory = self.get_directory_client(directory_name)
await directory.delete_directory(**kwargs)
Loading