diff --git a/mailnews/base/search/resources/content/FilterListDialog.js b/mailnews/base/search/resources/content/FilterListDialog.js index 4dc129b2544..7610d0f0fa6 100644 --- a/mailnews/base/search/resources/content/FilterListDialog.js +++ b/mailnews/base/search/resources/content/FilterListDialog.js @@ -235,11 +235,10 @@ function setServer(uri) gCurrentServerURI = uri; } -function toggleFilter(aFilterURI) +function toggleFilter(aResource) { - var filterResource = gRDF.GetResource(aFilterURI); - var filter = filterResource.GetDelegate("filter", - Components.interfaces.nsIMsgFilter); + var filter = aResource.GetDelegate("filter", + Components.interfaces.nsIMsgFilter); if (filter.unparseable) { if (gPromptService) @@ -605,8 +604,7 @@ function onFilterClick(event) } if (col.value.id == "activeColumn") { - var res = filterTree.builderView.getResourceAtIndex(row.value); - toggleFilter(res.Value); + toggleFilter(filterTree.builderView.getResourceAtIndex(row.value)); } } @@ -641,8 +639,7 @@ function onFilterTreeKeyPress(event) var start = {}, end = {}; gFilterTree.view.selection.getRangeAt(i, start, end); for (var k = start.value; k <= end.value; ++k) { - var res = gFilterTree.builderView.getResourceAtIndex(k); - toggleFilter(res.Value); + toggleFilter(gFilterTree.builderView.getResourceAtIndex(k)); } } }