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
fbede6ab
Commit
fbede6ab
authored
Jul 22, 2015
by
Roman S
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #247 from ishmakov/master
Fix collection requests XEP-0059
parents
0e1ad53c
5beaf97c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
8 deletions
+13
-8
XmppResultSet.java
...reucon/openfire/plugin/archive/xep0059/XmppResultSet.java
+1
-1
IQRetrieveHandler.java
...on/openfire/plugin/archive/xep0136/IQRetrieveHandler.java
+12
-7
No files found.
src/plugins/monitoring/src/java/com/reucon/openfire/plugin/archive/xep0059/XmppResultSet.java
View file @
fbede6ab
...
...
@@ -49,7 +49,7 @@ public class XmppResultSet
catch
(
NumberFormatException
e
)
{
if
(
setElement
.
elementText
(
"before"
).
isEmpty
())
{
this
.
before
=
Long
.
valueOf
(
9223372036854775807L
)
;
this
.
before
=
Long
.
MAX_VALUE
;
}
}
catch
(
Exception
e
)
...
...
src/plugins/monitoring/src/java/com/reucon/openfire/plugin/archive/xep0136/IQRetrieveHandler.java
View file @
fbede6ab
...
...
@@ -61,7 +61,10 @@ public class IQRetrieveHandler extends AbstractIQHandler {
fromIndex
=
resultSet
.
getAfter
().
intValue
()
+
1
;
toIndex
=
fromIndex
+
max
;
}
else
if
(
resultSet
.
getBefore
()
!=
null
)
{
if
(
resultSet
.
getBefore
()!=
Long
.
MAX_VALUE
)
toIndex
=
resultSet
.
getBefore
().
intValue
();
else
toIndex
=
conversation
.
getMessages
().
size
();
fromIndex
=
toIndex
-
max
;
}
}
...
...
@@ -76,10 +79,12 @@ public class IQRetrieveHandler extends AbstractIQHandler {
addMessageElement
(
chatElement
,
conversation
,
message
);
}
if
(
resultSet
!=
null
&&
messages
.
size
()
>
0
)
{
if
(
resultSet
!=
null
)
{
if
(
messages
.
size
()
>
0
)
{
resultSet
.
setFirst
((
long
)
fromIndex
);
resultSet
.
setFirstIndex
(
fromIndex
);
resultSet
.
setLast
((
long
)
toIndex
-
1
);
}
resultSet
.
setCount
(
conversation
.
getMessages
().
size
());
chatElement
.
add
(
resultSet
.
createResultElement
());
}
...
...
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