mirror of
https://github.com/M66B/FairEmail.git
synced 2026-04-05 16:43:26 +02:00
Prevent crash
This commit is contained in:
@@ -506,7 +506,9 @@ public class FragmentDialogOpenLink extends FragmentDialogBase {
|
||||
if (host != null) {
|
||||
int textColorLink = Helper.resolveColor(context, android.R.attr.textColorLink);
|
||||
int index = text.indexOf(host);
|
||||
ssb.setSpan(new ForegroundColorSpan(textColorLink), index, index + host.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
if (index >= 0)
|
||||
ssb.setSpan(new ForegroundColorSpan(textColorLink),
|
||||
index, index + host.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
}
|
||||
return ssb;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user