Commit 084e881c authored by Daniel Wolf's avatar Daniel Wolf
Browse files

For whatever reason I got crash reports that the server is null here (even...

For whatever reason I got crash reports that the server is null here (even though it can't possibly be)
parent 67222d6b
...@@ -391,7 +391,10 @@ public class MainFragment extends Fragment { ...@@ -391,7 +391,10 @@ public class MainFragment extends Fragment {
_text = _text.replace("[x]", unreachable.size() + reachable.size() + ""); _text = _text.replace("[x]", unreachable.size() + reachable.size() + "");
_text = _text.replace("[y]", unreachable.size() + ""); _text = _text.replace("[y]", unreachable.size() + "");
boolean customPorts = PreferencesAccessor.areCustomPortsEnabled(requireContext()); boolean customPorts = PreferencesAccessor.areCustomPortsEnabled(requireContext());
for(IPPortPair p: unreachable) builder.append("- ").append(p.formatForTextfield(customPorts)).append("\n"); for(IPPortPair p: unreachable) {
if(p == null)continue;
builder.append("- ").append(p.formatForTextfield(customPorts)).append("\n");
}
_text = _text.replace("[servers]", builder.toString()); _text = _text.replace("[servers]", builder.toString());
final String text = _text; final String text = _text;
((MainActivity)requireContext()).runOnUiThread(new Runnable() { ((MainActivity)requireContext()).runOnUiThread(new Runnable() {
......
Supports Markdown
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