 
   @tokens = ['zooHome', 'zooTalk', 'zooniverse/gravity-spy']
 
-  keys: {}
+  keys: 
+    projectToken: 'zooHome'
 
   geordi: null
 


  makeGeordi: (projectSlug) ->
    new GeordiClient
      server: @state?.env
      projectToken: projectSlug || ''
      zooUserIDGetter: () => @state.user?.id
      subjectGetter: () => @keys?.subjectID


            data: "\"#{eventData}\""

  logEvent: (logEntry) -> # Accepts key/values to make appropriate Geordi logging
    newEntry = Object.assign {}, logEntry, @keys
    if GeordiLogger.tokens.indexOf(newEntry.projectToken) > -1
      @instance().logEvent newEntry
      console.log 'No logger available for event ', JSON.stringify(logEntry) unless @instance().logEvent

  remember: (keyVals) ->
    reset = keyVals?.projectToken? && (keyVals?.projectToken != @geordi?.projectToken)
    @instance().update {projectToken: keyVals.projectToken} if reset
    @keys = Object.assign {}, @keys, keyVals

  forget: (forgetKeys) ->
    reset = false
    for key in forgetKeys
      reset = (key == 'projectToken')
      delete @keys[key]

    @instance().update {projectToken: 'zooHome'} if reset

module.exports = React.createClass
  displayName: 'PanoptesApp'
