     @projectFindView?.remove()
     @projectFindView = null
 
+    ResultsPaneView.model = null
+    @resultsModel = null
+
   serialize: ->
-    viewState: @findView.serialize()
-    projectViewState: @projectFindView.serialize()
-    resultsModelState: @resultsModel.serialize()
+    viewState: @findView?.serialize() ? @viewState
+    projectViewState: @projectFindView?.serialize() ? @projectViewState
+    resultsModelState: @resultsModel?.serialize() ? @resultsModelState

      @findView?.detach()
      @projectFindView?.detach()

  createProjectFindView: (projectViewState, resultsModelState) ->
    @resultsModel ?= new ResultsModel(resultsModelState)
    @projectFindView ?= new ProjectFindView(@resultsModel, projectViewState)

    # HACK: Soooo, we need to get the model to the pane view whenever it is
    # created. Creation could come from the opener below, or, more problematic,

    # See https://github.com/atom/find-and-replace/issues/63
    ResultsPaneView.model = @resultsModel

  createFindView: ->
    @findView ?= new FindView(@viewState)

  deactivate: ->
    @findView?.remove()
