Skip to content
Snippets Groups Projects
Commit 3f4d5f86 authored by Florian Hölzl's avatar Florian Hölzl
Browse files

fixed NPE

refs 311
parent ef351add
No related branches found
No related tags found
No related merge requests found
...@@ -43,7 +43,7 @@ import org.osgi.framework.Bundle; ...@@ -43,7 +43,7 @@ import org.osgi.framework.Bundle;
* @author hoelzl * @author hoelzl
* @author $Author$ * @author $Author$
* @version $Rev$ * @version $Rev$
* @ConQAT.Rating GREEN Hash: 794D71DA1264AB09BBB8AE9A13C77E47 * @ConQAT.Rating YELLOW Hash: D5BB94A9DB8CACB9E4142CEE1206C1B1
*/ */
public class ContextMenuService implements IContextMenuService { public class ContextMenuService implements IContextMenuService {
...@@ -136,8 +136,12 @@ public class ContextMenuService implements IContextMenuService { ...@@ -136,8 +136,12 @@ public class ContextMenuService implements IContextMenuService {
if (menuSectionID == null) { if (menuSectionID == null) {
menuSectionID = IWorkbenchActionConstants.MB_ADDITIONS; menuSectionID = IWorkbenchActionConstants.MB_ADDITIONS;
} }
for (IContributionItem item : contributor.getContributedItems( List<IContributionItem> l = contributor.getContributedItems(
selection, contextProvider)) { selection, contextProvider);
if (l == null) {
continue;
}
for (IContributionItem item : l) {
menu.appendToGroup(menuSectionID, item); menu.appendToGroup(menuSectionID, item);
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment