     var window: UIWindow?
     var appController: TVApplicationController?
 
-    // Uncomment the following line to debug 
+    // Uncomment the following line to debug
     // static let TVBaseURL = "http://localhost/appletv/jwplayer-appletv-web-app"
     static let TVBaseURL = "https://tvos.jwpsrv.com"
     static let TVConfigURL = "\(AppDelegate.TVBaseURL)/resources/configs"

                }
            }
        }
        
        self.appController = TVApplicationController(context: appControllerContext, window: self.window, delegate: self)
        
        return true
    }
}


    func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool {
        // Override point for customization after application launch.
        self.window = UIWindow(frame: UIScreen.mainScreen().bounds)

        let infoBundle = NSBundle.mainBundle()

        let appControllerContext = TVApplicationControllerContext()


        appControllerContext.launchOptions["baseURL"] = AppDelegate.TVBaseURL
        appControllerContext.launchOptions["configService"] = AppDelegate.TVConfigURL
        appControllerContext.launchOptions["account_key"] = infoBundle.infoDictionary?["jwplayer.account_key"]
        appControllerContext.javaScriptApplicationURL = NSURL(string: AppDelegate.TVBootURL)!

        if let options = launchOptions {
            for (kind, value) in options {
                if let kindStr = kind as? String {
