Merge pull request #5536 from ByteHamster/fix-sync-crash
Fix crash when sync provider is null
This commit is contained in:
commit
3856597211
|
@ -346,7 +346,10 @@ public class SyncService extends Worker {
|
|||
private ISyncService getActiveSyncProvider() {
|
||||
String selectedSyncProviderKey = SynchronizationSettings.getSelectedSyncProviderKey();
|
||||
SynchronizationProviderViewData selectedService = SynchronizationProviderViewData
|
||||
.valueOf(selectedSyncProviderKey);
|
||||
.fromIdentifier(selectedSyncProviderKey);
|
||||
if (selectedService == null) {
|
||||
return null;
|
||||
}
|
||||
switch (selectedService) {
|
||||
case GPODDER_NET:
|
||||
return new GpodnetService(AntennapodHttpClient.getHttpClient(),
|
||||
|
|
Loading…
Reference in New Issue