diff --git a/javascript/atoms/dom.js b/javascript/atoms/dom.js
index <HASH>..<HASH> 100644
--- a/javascript/atoms/dom.js
+++ b/javascript/atoms/dom.js
@@ -629,7 +629,9 @@ bot.dom.getElementSize = function(element) {
   // If the element is the BODY, then get the visible size.
   if (bot.dom.isElement(element, goog.dom.TagName.BODY)) {
     var doc = goog.dom.getOwnerDocument(element);
-    var win = goog.dom.getWindow(doc);
+    // Type annotation is incorrect on goog.dom.getWindow. It will always
+    // return a non-null window.
+    var win = (/** @type {!Window} */goog.dom.getWindow(doc));
     if (bot.dom.getEffectiveStyle(element, 'overflow') == 'hidden') {
       return goog.dom.getViewportSize(win);
     }
JasonLeyba: The type annotation is incorrect on goog.dom.getWindow; it will
always return a non-null Window.

r<I>