Commit 7ef6b4a7 authored by Tom Evans's avatar Tom Evans

OF-122: Use strict policy by default

Per PR feedback, default to a strict (conforming) policy when detecting
MUC room subject change requests.

Additional work could be done to add a corresponding configuration
option to the MUC service admin console, but is not included in the
scope of this PR.
parent bc5faf4b
...@@ -336,8 +336,8 @@ public class HistoryStrategy { ...@@ -336,8 +336,8 @@ public class HistoryStrategy {
// where the <message/> MUST contain a <subject/> element that specifies the new subject // where the <message/> MUST contain a <subject/> element that specifies the new subject
// but MUST NOT contain a <body/> element (or a <thread/> element). // but MUST NOT contain a <body/> element (or a <thread/> element).
// Unfortunately, many clients do not follow these strict guidelines from the specs, so we // Unfortunately, many clients do not follow these strict guidelines from the specs, so we
// implement a lenient policy for detecting subject change requests by default. This can // allow a lenient policy for detecting non-conforming subject change requests. This can be
// be overridden by setting the "xmpp.muc.subject.change.strict" property to true. // configured by setting the "xmpp.muc.subject.change.strict" property to false (true by default).
// An empty <subject/> value means that the room subject should be removed. // An empty <subject/> value means that the room subject should be removed.
return Message.Type.groupchat == message.getType() && return Message.Type.groupchat == message.getType() &&
...@@ -348,7 +348,7 @@ public class HistoryStrategy { ...@@ -348,7 +348,7 @@ public class HistoryStrategy {
} }
private boolean isSubjectChangeStrict() { private boolean isSubjectChangeStrict() {
return JiveGlobals.getBooleanProperty("xmpp.muc.subject.change.strict", false); return JiveGlobals.getBooleanProperty("xmpp.muc.subject.change.strict", true);
} }
private static class MessageComparator implements Comparator<Message> { private static class MessageComparator implements Comparator<Message> {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment