Skip to content

Commit 167c564

Browse files
authored
Merge pull request #24 from Vigilans/vigilans/fix-supportedlock
Fix wrong XML format for `supportedlock` prop
2 parents 8972c98 + 574e78a commit 167c564

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/handle_lock.rs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -242,16 +242,20 @@ pub(crate) fn list_supportedlock(ls: Option<&Box<dyn DavLockSystem>>) -> Element
242242

243243
let mut entry = Element::new2("D:lockentry");
244244
let mut scope = Element::new2("D:lockscope");
245+
let mut ltype = Element::new2("D:locktype");
245246
scope.push_element(Element::new2("D:exclusive"));
246-
scope.push_element(Element::new2("D:write"));
247+
ltype.push_element(Element::new2("D:write"));
247248
entry.push_element(scope);
249+
entry.push_element(ltype);
248250
elem.push_element(entry);
249251

250252
let mut entry = Element::new2("D:lockentry");
251253
let mut scope = Element::new2("D:lockscope");
254+
let mut ltype = Element::new2("D:locktype");
252255
scope.push_element(Element::new2("D:shared"));
253-
scope.push_element(Element::new2("D:write"));
256+
ltype.push_element(Element::new2("D:write"));
254257
entry.push_element(scope);
258+
entry.push_element(ltype);
255259
elem.push_element(entry);
256260

257261
elem

0 commit comments

Comments
 (0)