Attention

You are looking at outdated documentation for version 2.x. A newer version is available.

wsgidav.util.getUriParent

wsgidav.util.getUriParent(uri)[source]

Return URI of parent collection with trailing ‘/’, or None, if URI is top-level.

This function simply strips the last segment. It does not test, if the target is a ‘collection’, or even exists.