1
0
mirror of https://github.com/moparisthebest/k-9 synced 2024-11-16 14:35:04 -05:00

Bullet-proof an NPE I ran into on a 2.2 test emulator while on an airplane

This commit is contained in:
Jesse Vincent 2012-09-12 18:54:06 -04:00
parent 2a05bc0caa
commit 593569f4ad

View File

@ -1990,7 +1990,7 @@ public class MessageList extends K9ListActivity implements OnItemClickListener {
Folder folder; Folder folder;
for (MessageInfoHolder holder : mMessages) { for (MessageInfoHolder holder : mMessages) {
uid = message.getUid(); uid = message.getUid();
if (holder.uid == uid || uid.equals(holder.uid)) { if (uid != null && (holder.uid == uid || uid.equals(holder.uid))) {
folder = message.getFolder(); folder = message.getFolder();
if (holder.folder.name.equals(folder.getName()) && if (holder.folder.name.equals(folder.getName()) &&
holder.account.equals(folder.getAccount().getUuid())) { holder.account.equals(folder.getAccount().getUuid())) {