android: Throw an exception if UUID can't get parsed

The parser is quite picky and e.g. doesn't accept UUIDs without dashes.
Even without a specific error, this at least points the users into the
right direction.

Fixes #3583.
This commit is contained in:
Tobias Brunner 2020-10-19 17:52:15 +02:00
parent 80337f4f9d
commit ec317c29ca
1 changed files with 1 additions and 2 deletions

View File

@ -463,8 +463,7 @@ public class VpnProfileImportActivity extends AppCompatActivity
}
catch (IllegalArgumentException e)
{
e.printStackTrace();
return null;
throw new JSONException(getString(R.string.profile_import_failed_value, "uuid"));
}
ParsedVpnProfile profile = new ParsedVpnProfile();
Integer flags = 0;