From 10ee1a626224b1d025b603011c481c737870e4da Mon Sep 17 00:00:00 2001 From: Steve Orvell Date: Wed, 6 Nov 2013 14:02:01 -0800 Subject: [PATCH] ensure window.Polymer is an object. This allows proper manipulation of it via extend. --- src/boot.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/boot.js b/src/boot.js index a37b177f8e..7d9e0a0b77 100644 --- a/src/boot.js +++ b/src/boot.js @@ -4,8 +4,15 @@ * license that can be found in the LICENSE file. */ -(function(scope) { +// TODO(sorvell): this ensures Polymer is an object and not a function +// Platform is currently defining it as a function to allow for async loading +// of polymer; once we refine the loading process this likely goes away. +if (typeof window.Polymer === 'function') { + Polymer = {}; +} + +(function(scope) { // FOUC prevention tactic // default list of veiled elements scope.veiledElements = ['body'];