 ###
-Copyright (c) 2012 Markus Kohlhase <mail@markus-kohlhase.de>
+Copyright (c) 2012 - 2013 Markus Kohlhase <mail@markus-kohlhase.de>
 ###
 
 throw new Error "This plugin only can be used in the browser" unless window?

restoreData = ->
  if localStorage?
    for k in [ "jid", "sid", "rid", "host", "port", "path" ]
      j = cache2key k
      connection_options[k] = localStorage[j]  if localStorage[j]

hasConnectionData = ->

    port: connection_options.port

key2cache   = (k) -> "#{CACHE_PREFIX}#{k}"

saveData = ->
  if localStorage?
