diff --git a/src/add-ons/mail_daemon/inbound_protocols/imap/IMAPFolderConfig.cpp b/src/add-ons/mail_daemon/inbound_protocols/imap/IMAPFolderConfig.cpp index d50bf147b2..e845ad1964 100644 --- a/src/add-ons/mail_daemon/inbound_protocols/imap/IMAPFolderConfig.cpp +++ b/src/add-ons/mail_daemon/inbound_protocols/imap/IMAPFolderConfig.cpp @@ -161,10 +161,7 @@ EditListView::MouseDown(BPoint where) BListView::MouseDown(where); int32 index = IndexOf(where); - BListItem* item = ItemAt(index); - if (item == NULL) - return; - EditableListItem* handler = dynamic_cast(item); + EditableListItem* handler = dynamic_cast(ItemAt(index)); if (handler == NULL) return; @@ -184,10 +181,7 @@ EditListView::MouseUp(BPoint where) } int32 index = IndexOf(where); - BListItem* item = ItemAt(index); - if (item == NULL) - return; - EditableListItem* handler = dynamic_cast(item); + EditableListItem* handler = dynamic_cast(ItemAt(index)); if (handler == NULL) return;