Commit ffecfbf1 authored by Yusuke Iwaki's avatar Yusuke Iwaki Committed by GitHub

Merge branch 'develop' into feature/version-bump-3

parents 57383b59 5c9c522e
......@@ -128,7 +128,7 @@ abstract class AbstractAuthedActivity extends AbstractFragmentActivity {
@Override
protected void onResume() {
super.onResume();
RocketChatService.keepalive(this);
RocketChatService.keepAlive(this);
unconfiguredServersObserver.sub();
SharedPreferences prefs = RocketChatCache.get(this);
......
......@@ -65,7 +65,7 @@ public class ServerConfigActivity extends AbstractFragmentActivity {
@Override
protected void onResume() {
super.onResume();
RocketChatService.keepalive(this);
RocketChatService.keepAlive(this);
serverConfigErrorObserver.sub();
}
......
......@@ -313,7 +313,7 @@ public class RoomFragment extends AbstractChatRoomFragment
.put("reset", true));
return null;
}).onSuccessTask(task -> {
RocketChatService.keepalive(getContext());
RocketChatService.keepAlive(getContext());
return task;
}).continueWith(new LogcatIfError());
}
......@@ -334,7 +334,7 @@ public class RoomFragment extends AbstractChatRoomFragment
}
return null;
}).onSuccessTask(task -> {
RocketChatService.keepalive(getContext());
RocketChatService.keepAlive(getContext());
return task;
}).continueWith(new LogcatIfError());
}
......
......@@ -91,7 +91,7 @@ public class UsersOfRoomDialogFragment extends AbstractChatroomDialogFragment {
.put("showAll", true));
return null;
}).onSuccessTask(task -> {
RocketChatService.keepalive(getContext());
RocketChatService.keepAlive(getContext());
return task;
}).continueWith(new LogcatIfError());
}
......
......@@ -25,7 +25,7 @@ public class ServerConfig extends RealmObject {
private String error;
/**
* Log the server connection is lost due to soem exception.
* Log the server connection is lost due to some exception.
*/
@DebugLog
public static void logConnectionError(String serverConfigId, Exception exception) {
......
......@@ -58,9 +58,9 @@ public class MethodCall extends RealmObject {
return;
}
int syncstate = methodCall.getSyncState();
RCLog.d("MethodCall[%s] syncstate=%d", methodCall.getMethodCallId(), syncstate);
if (syncstate == SyncState.SYNCED) {
int syncState = methodCall.getSyncState();
RCLog.d("MethodCall[%s] syncstate=%d", methodCall.getMethodCallId(), syncState);
if (syncState == SyncState.SYNCED) {
String resultJson = methodCall.getResultJson();
if (TextUtils.isEmpty(resultJson)) {
task.setResult(null);
......@@ -70,7 +70,7 @@ public class MethodCall extends RealmObject {
observer.unsub();
REF_MAP.remove(methodCall.getMethodCallId());
remove(realmHelper, methodCall.getMethodCallId()).continueWith(new LogcatIfError());
} else if (syncstate == SyncState.FAILED) {
} else if (syncState == SyncState.FAILED) {
task.setError(new Error(methodCall.getResultJson()));
observer.unsub();
REF_MAP.remove(methodCall.getMethodCallId());
......@@ -81,7 +81,7 @@ public class MethodCall extends RealmObject {
REF_MAP.put(newId, observer);
if (context != null) {
RocketChatService.keepalive(context);
RocketChatService.keepAlive(context);
}
}
return null;
......
......@@ -28,7 +28,7 @@ public class RocketChatService extends Service {
/**
* ensure RocketChatService alive.
*/
public static void keepalive(Context context) {
public static void keepAlive(Context context) {
context.startService(new Intent(context, RocketChatService.class));
}
......
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