       Promise.resolve false
 
   componentWillMount: ->
-    @findFavoriteCollection()
-      .then (favorites) =>
-        @setState {favorites}
-        @findSubjectInCollection()
-        .then (favorited) =>
-          @setState {favorited}
+    favorited = @props.isFavorite
+    @setState {favorited}
 
 
   componentDidUpdate: (prevProps) ->
     if prevProps.subject isnt @props.subject
-      @findSubjectInCollection()
-      .then (favorited) =>
-        @setState {favorited}
+      favorited = @props.isFavorite
+      @setState {favorited}
 
   addSubjectTo: (collection) ->
     @setState favorited: true

    subject: React.PropTypes.object # a subject response from panoptes
    project: React.PropTypes.object # a project response from panoptes
    user: React.PropTypes.object

  getDefaultProps: ->
    subject: null
    project: null
    user: null

  getInitialState: ->
    favorites: null

    collection.removeLink('subjects', [@props.subject.id.toString()])

  createFavorites: ->
    new Promise (resolve, reject) =>
      @findFavoriteCollection()
        .catch (err) ->
          reject err
        .then (favorites) =>
          if favorites?
            @setState {favorites}
            resolve favorites
          else
            display_name = getFavoritesName(@props.project)
            project = @props.project?.id
            subjects = []
            favorite = true

            links = {subjects}
            links.projects = [ project ] if project?
            collection = {favorite, display_name, links}
            apiClient.type('collections')
              .create(collection)
              .save()
              .catch (err) ->
                reject err
              .then (favorites) =>
                @setState {favorites}
                resolve favorites

  toggleFavorite: ->
    if @props.user?
      if not @state.favorites?
        @setState favorited: true
        @createFavorites()
        .then (favorites) =>
          @addSubjectTo(favorites)
        @logSubjLike 'favorite'
      else if @state.favorited
        @removeSubjectFrom(@state.favorites)
