 
     # Monitoring changes in settings
     settings ?= require './vendor/settings'
+    fs ?= require 'fs-plus'
     # TODO: Watch for changing profile
-    # FIXME: Error when file doesn't exist
-    @watchSubscription ?= @PathWatcher.watch settings.findOverridesFile(), (eventType) =>
-      if eventType is 'change' and @watchSubscription?
-        @updateToolbarButtons()
-        @MenuManager.update()
-        atom.workspaceView.trigger 'spark-ide:update-login-status'
+    @watchConfig()
 
   deactivate: ->
     @statusView?.destroy()

      @compileButton.setEnabled false
      @coreButton.setEnabled false
      @wifiButton.setEnabled false

  # Function for selecting port or showing Listen dialog
  choosePort: (delegate) ->

      pane.activate()
      atom.workspace.open uri, searchAllPanes: true

  # Enables/disables toolbar buttons based on log in state
  updateToolbarButtons: ->
    if @SettingsHelper.isLoggedIn()
      @compileButton.setEnabled true
