Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
AloqaIM-Android
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
AloqaIM-Android
Commits
24bf24d6
Commit
24bf24d6
authored
Jul 22, 2017
by
Leonardo Aramaki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed unused imports and RxWebSocketCallback Failure class
parent
40a217f0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
28 deletions
+2
-28
DDPClientImpl.java
.../src/main/java/chat/rocket/android_ddp/DDPClientImpl.java
+2
-4
RxWebSocketCallback.java
.../java/chat/rocket/android_ddp/rx/RxWebSocketCallback.java
+0
-24
No files found.
android-ddp/src/main/java/chat/rocket/android_ddp/DDPClientImpl.java
View file @
24bf24d6
...
@@ -378,10 +378,8 @@ public class DDPClientImpl {
...
@@ -378,10 +378,8 @@ public class DDPClientImpl {
private
void
sendMessage
(
String
msg
,
@Nullable
JSONBuilder
json
,
private
void
sendMessage
(
String
msg
,
@Nullable
JSONBuilder
json
,
TaskCompletionSource
<?>
taskForSetError
)
{
TaskCompletionSource
<?>
taskForSetError
)
{
if
(!
sendMessage
(
msg
,
json
))
{
if
(!
sendMessage
(
msg
,
json
)
&&
taskForSetError
!=
null
)
{
if
(
taskForSetError
!=
null
)
{
taskForSetError
.
trySetError
(
new
DDPClientCallback
.
Closed
(
client
));
taskForSetError
.
trySetError
(
new
DDPClientCallback
.
Closed
(
client
));
}
}
}
}
}
...
...
android-ddp/src/main/java/chat/rocket/android_ddp/rx/RxWebSocketCallback.java
View file @
24bf24d6
package
chat
.
rocket
.
android_ddp
.
rx
;
package
chat
.
rocket
.
android_ddp
.
rx
;
import
static
android
.
R
.
attr
.
resizeable
;
import
static
android
.
R
.
attr
.
type
;
import
chat.rocket.android.log.RCLog
;
import
chat.rocket.android.log.RCLog
;
import
okhttp3.Response
;
import
okhttp3.Response
;
import
okhttp3.WebSocket
;
import
okhttp3.WebSocket
;
...
@@ -35,27 +32,6 @@ public class RxWebSocketCallback {
...
@@ -35,27 +32,6 @@ public class RxWebSocketCallback {
}
}
}
}
public
static
class
Failure
extends
Base
{
public
Response
response
;
public
Failure
(
WebSocket
websocket
,
Throwable
err
,
Response
response
)
{
super
(
"Failure"
,
websocket
);
this
.
response
=
response
;
if
(
response
!=
null
&&
response
.
body
()
!=
null
)
{
this
.
response
.
body
().
close
();
}
}
@Override
public
String
toString
()
{
if
(
response
!=
null
)
{
return
"["
+
type
+
"] "
+
response
.
message
();
}
else
{
return
super
.
toString
();
}
}
}
public
static
class
Message
extends
Base
{
public
static
class
Message
extends
Base
{
public
String
responseBodyString
;
public
String
responseBodyString
;
...
...
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