plugin XEP-0384: be sure to have open access model for created nodes.

This commit is contained in:
Goffi 2024-03-05 17:31:36 +01:00
commit 23e7b2720d

View file

@ -873,6 +873,7 @@ def make_session_manager(sat: LiberviaBackend, profile: str) -> Type[omemo.Sessi
item_id=str(bundle.device_id),
extra={
XEP_0060.EXTRA_PUBLISH_OPTIONS: {
XEP_0060.OPT_ACCESS_MODEL: "open",
XEP_0060.OPT_MAX_ITEMS: "max"
},
XEP_0060.EXTRA_ON_PRECOND_NOT_MET: "raise"
@ -912,7 +913,10 @@ def make_session_manager(sat: LiberviaBackend, profile: str) -> Type[omemo.Sessi
xml_tools.et_elt_2_domish_elt(element),
item_id=xep_0060.ID_SINGLETON,
extra={
XEP_0060.EXTRA_PUBLISH_OPTIONS: { XEP_0060.OPT_MAX_ITEMS: 1 },
XEP_0060.EXTRA_PUBLISH_OPTIONS: {
XEP_0060.OPT_ACCESS_MODEL: "open",
XEP_0060.OPT_MAX_ITEMS: 1
},
XEP_0060.EXTRA_ON_PRECOND_NOT_MET: "publish_without_options"
}
)