diff --git a/app/src/main/java/com/nutomic/syncthingandroid/activities/ShareActivity.java b/app/src/main/java/com/nutomic/syncthingandroid/activities/ShareActivity.java index 0474ef4c..60754a41 100644 --- a/app/src/main/java/com/nutomic/syncthingandroid/activities/ShareActivity.java +++ b/app/src/main/java/com/nutomic/syncthingandroid/activities/ShareActivity.java @@ -29,6 +29,7 @@ import com.nutomic.syncthingandroid.model.Folder; import com.nutomic.syncthingandroid.service.SyncthingService; import com.nutomic.syncthingandroid.service.SyncthingServiceBinder; import com.nutomic.syncthingandroid.util.ConfigRouter; +import com.nutomic.syncthingandroid.util.ConfigXml.OpenConfigException; import com.nutomic.syncthingandroid.util.Util; import java.io.File; @@ -76,7 +77,14 @@ public class ShareActivity extends SyncthingActivity @Override public void onServiceStateChange(SyncthingService.State currentState) { - List folders = mConfig.getFolders(getApi()); + List folders = null; + try { + folders = mConfig.getFolders(getApi()); + } catch (OpenConfigException e) { + Toast.makeText(this, getString(R.string.complete_welcome_wizard_first), Toast.LENGTH_LONG).show(); + finish(); + return; + } // Get the index of the previously selected folder. int folderIndex = 0; diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index 547bdf6c..e595ebb0 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -703,6 +703,9 @@ Bitte melden Sie auftretende Probleme via GitHub. + + Starte zuerst die App aus der App-Übersicht und schließe den Willkommensassistenten ab, bevor Du Dateien teilst. + Speichern in Syncthing diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index c893d167..3c8cf842 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -724,6 +724,9 @@ Please report any problems you encounter via Github. + + First, launch the app from the app drawer and complete the welcome wizard before sharing files. + Save to Syncthing