Added null check for window.ext - fix for bug 70057

Change-Id: I85d9e98e64b1e1fc998105422cf15b6162afa58f