If we don't find something by name in a named array fall through to the index based array.

git-svn-id: svn://10.0.0.236/branches/XPCDOM_20010329_BRANCH@93897 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
jst%netscape.com
2001-05-04 06:08:42 +00:00
parent eca4535211
commit d77ac36399

View File

@@ -1994,14 +1994,15 @@ nsNamedArraySH::GetProperty(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
nsresult rv = GetNamedItem(native, name, getter_AddRefs(item));
NS_ENSURE_SUCCESS(rv, rv);
// Do we wanto fall through to nsArraySH::GetProperty() here if
// item is null?
if (item) {
rv = WrapNative(cx, ::JS_GetGlobalObject(cx), item,
NS_GET_IID(nsISupports), vp);
NS_ENSURE_SUCCESS(rv, rv);
rv = WrapNative(cx, ::JS_GetGlobalObject(cx), item,
NS_GET_IID(nsISupports), vp);
NS_ENSURE_SUCCESS(rv, rv);
return NS_OK;
}
return NS_OK;
// Fall through to nsArraySH::GetProperty() here
}
return nsArraySH::GetProperty(wrapper, cx, obj, id, vp, _retval);