diff --git a/radicale/web/fn.js b/radicale/web/fn.js
index 2a47b809..03334949 100644
--- a/radicale/web/fn.js
+++ b/radicale/web/fn.js
@@ -339,14 +339,24 @@ function create_edit_collection(user, password, collection, create, callback) {
'' +
'' +
(create ? '' + resourcetype + '' : '') +
- '' + components + '' +
- '' + displayname + '' +
- '' + calendar_color + '' +
- '' + addressbook_color + '' +
- '' + addressbook_description + '' +
- '' + calendar_description + '' +
+ (components ? '' + components + '' : '') +
+ (displayname ? '' + displayname + '' : '') +
+ (calendar_color ? '' + calendar_color + '' : '') +
+ (addressbook_color ? '' + addressbook_color + '' : '') +
+ (addressbook_description ? '' + addressbook_description + '' : '') +
+ (calendar_description ? '' + calendar_description + '' : '') +
'' +
'' +
+ (!create ? ('' +
+ '' +
+ (!components ? '' : '') +
+ (!displayname ? '' : '') +
+ (!calendar_color ? '' : '') +
+ (!addressbook_color ? '' : '') +
+ (!addressbook_description ? '' : '') +
+ (!calendar_description ? '' : '') +
+ '' +
+ ''): '') +
'' + xml_request + '>');
return request;
}