Guarding webview attributes against polluted Object.prototypes

Ran into an error with the buildParams function breaking when using a JavaScript library that modified the Object.prototype, this small fix resolves the issue.
This commit is contained in:
Kirk Ouimet 2015-06-09 16:17:00 -07:00
parent f91a81fe77
commit 0fef09281b

View file

@ -173,7 +173,7 @@ class WebViewImpl
params =
instanceId: @viewInstanceId
userAgentOverride: @userAgentOverride
for attributeName, attribute of @attributes
for own attributeName, attribute of @attributes
params[attributeName] = attribute.getValue()
# When the WebView is not participating in layout (display:none)
# then getBoundingClientRect() would report a width and height of 0.