Fix crashes
This commit is contained in:
parent
cbc5eddc9c
commit
64e50bd8b5
|
@ -183,6 +183,12 @@ public class PinnedTimelineHelper {
|
|||
if (extraFeatures) {
|
||||
try {
|
||||
Pinned pinnedAll = new Pinned(activity).getAllPinned(currentAccount);
|
||||
if (pinnedAll == null) {
|
||||
pinnedAll = new Pinned();
|
||||
pinnedAll.user_id = currentUserID;
|
||||
pinnedAll.instance = currentInstance;
|
||||
pinnedAll.pinnedTimelines = new ArrayList<>();
|
||||
}
|
||||
boolean createDefaultBubbleAtTop = true;
|
||||
for (PinnedTimeline pinnedTimeline : pinnedAll.pinnedTimelines) {
|
||||
if (pinnedTimeline.type == Timeline.TimeLineEnum.BUBBLE) {
|
||||
|
|
|
@ -299,6 +299,9 @@ public class SpannableHelper {
|
|||
}
|
||||
int matchEnd = start + newUrl.length();
|
||||
String finalUrl = url;
|
||||
if (content.length() < matchEnd) {
|
||||
matchEnd = content.length();
|
||||
}
|
||||
content.setSpan(new LongClickableSpan() {
|
||||
@Override
|
||||
public void onLongClick(View view) {
|
||||
|
|
|
@ -718,10 +718,12 @@ public class FragmentMastodonTimeline extends Fragment implements StatusAdapter.
|
|||
timelineParams.remote = true;
|
||||
break;
|
||||
case BUBBLE:
|
||||
timelineParams.onlyMedia = bubbleTimeline.only_media;
|
||||
timelineParams.remote = bubbleTimeline.remote;
|
||||
timelineParams.replyVisibility = bubbleTimeline.reply_visibility;
|
||||
timelineParams.excludeVisibilities = bubbleTimeline.exclude_visibilities;
|
||||
if (bubbleTimeline != null) {
|
||||
timelineParams.onlyMedia = bubbleTimeline.only_media;
|
||||
timelineParams.remote = bubbleTimeline.remote;
|
||||
timelineParams.replyVisibility = bubbleTimeline.reply_visibility;
|
||||
timelineParams.excludeVisibilities = bubbleTimeline.exclude_visibilities;
|
||||
}
|
||||
break;
|
||||
case LIST:
|
||||
timelineParams.listId = list_id;
|
||||
|
|
Loading…
Reference in New Issue