Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
Openfire
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
Openfire
Commits
efd07556
Commit
efd07556
authored
Apr 26, 2017
by
Guus der Kinderen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
OF-1311: Lists should retain their order.
parent
ed65536b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
JiveGlobals.java
src/java/org/jivesoftware/util/JiveGlobals.java
+5
-3
No files found.
src/java/org/jivesoftware/util/JiveGlobals.java
View file @
efd07556
...
...
@@ -724,7 +724,9 @@ public class JiveGlobals {
// Check for a legacy, comma separated value.
final
String
legacyValue
=
JiveGlobals
.
getProperty
(
parent
);
final
Collection
<
String
>
propertyNames
=
properties
.
getChildrenNames
(
parent
);
// Ensure that properties are ordered.
final
SortedSet
<
String
>
propertyNames
=
new
TreeSet
<>(
properties
.
getChildrenNames
(
parent
)
);
if
(
propertyNames
.
isEmpty
()
)
{
if
(
legacyValue
!=
null
)
...
...
@@ -834,7 +836,7 @@ public class JiveGlobals {
{
if
(
value
!=
null
&&
!
value
.
isEmpty
()
)
{
final
String
childName
=
name
+
"."
+
i
++
;
final
String
childName
=
name
+
"."
+
String
.
format
(
"%05d"
,
i
++
)
;
properties
.
put
(
childName
,
value
);
}
}
...
...
@@ -842,7 +844,7 @@ public class JiveGlobals {
// When no non-null, non-empty values are stored, store one to denote an empty collection.
if
(
i
==
1
)
{
properties
.
put
(
name
+
".1"
,
""
);
properties
.
put
(
name
+
".
0000
1"
,
""
);
}
// The put's above will have generated events for each child property. Now, generate an event for the parent.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment