dom111 / webdav-js

A simple WebDAV client written in JS for use as a bookmarklet, or integration into a web server.
MIT License
91 stars 18 forks source link

Propfind Not Allowed: Fall back to regular link #107

Open chrysn opened 2 years ago

chrysn commented 2 years ago

A WebDAV server can be embedded in a context where not everything around it is WebDAV; for example, there could be some web site with a /files/ section that is WebDAV enabled and uses webdav-js as its index.html (or, more atypically, a single folder could have WebDAV disabled).

When directory navigation reaches such a point, a PROPFIND ${path} failed: Not Allowed (405) message is shown, and the view keeps spinning. The better behavior IMO would be to fall back to just navigating the browser there -- chances are it will succeed in a GET and can do something more sensible.