Skip to content

Commit

Permalink
Fix crash in ContactsManager with getString
Browse files Browse the repository at this point in the history
  • Loading branch information
DatBewar committed Mar 8, 2017
1 parent aadf3a4 commit 161ac91
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/org/linphone/ContactsManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,9 @@ private synchronized void fetchContactsSync() {
setSipContacts(sipContacts);

if (LinphonePreferences.instance() != null && LinphonePreferences.instance().isFriendlistsubscriptionEnabled()) {
LinphoneManager.getLc().getFriendLists()[0].setRLSUri(getString(R.string.rls_uri));
if (getString(R.string.rls_uri) != null) {
LinphoneManager.getLc().getFriendLists()[0].setRLSUri(getString(R.string.rls_uri));
}
LinphoneManager.getLc().getFriendLists()[0].updateSubscriptions();
}
for (ContactsUpdatedListener listener : contactsUpdatedListeners) {
Expand Down Expand Up @@ -484,6 +486,7 @@ public void deleteMultipleContactsAtOnce(List<String> ids) {
}

public String getString(int resourceID) {
if (context == null) return null;
return context.getString(resourceID);
}

Expand Down

0 comments on commit 161ac91

Please sign in to comment.