 
         if NSScreen.screensHaveSeparateSpaces() {
             for screenDictionary in screenDictionaries {
-                let screenIdentifier = screenDictionary["Display Identifier"] as? String
-                let screenManager = screenManagersCache.objectForKey(screenIdentifier!) as! ScreenManager
+                guard let screenIdentifier = screenDictionary["Display Identifier"] as? String else {
+                    LogManager.log?.error("Could not identify screen with info: \(screenDictionary)")
+                    continue
+                }
+
+                guard let screenManager = screenManagersCache[screenIdentifier] else {
+                    LogManager.log?.error("Screen with identifier not managed: \(screenIdentifier)")
+                    continue
+                }
 
                 guard let spaceIdentifier = spaceIdentifierWithScreenDictionary(screenDictionary) where screenManager.currentSpaceIdentifier != spaceIdentifier else {
                     continue


        for screen in NSScreen.screens() ?? [] {
            let screenIdentifier = screen.screenIdentifier()
            var screenManager: ScreenManager? = screenManagersCache.objectForKey(screenIdentifier) as? ScreenManager

            if screenManager == nil {
                screenManager = ScreenManager(screen:screen, screenIdentifier:screenIdentifier, delegate:self)
                screenManagersCache.setObject(screenManager!, forKey:screenIdentifier)
            }

            screenManager!.screen = screen

    internal let windowModifier = WindowModifier()

    internal var screenManagers: [ScreenManager] = []
    private var screenManagersCache: [String: ScreenManager] = [:]

    private let focusFollowsMouseManager = FocusFollowsMouseManager()

