Bug 982556 - JavaScript Error: "TypeError: self.app is null"