     setTimeout(
       ->
         if      o.listen  then (if o._[0] then $listenPort.val o._[0]); $listen.click()
-        else if o.spawn   then (if o._[0] then $spawnPort.val  o._[0]); $spawn.click()
+        else if o.spawn   then $spawn.click()
         else if o.connect then hp = parseFav o.connect; D.socket.emit '*connect', host: hp.host, port: hp.port or DEFAULT_PORT
         return
       100 # TODO: race condition?

  $cancel.click ->
    x = parseFav $list.find(':selected').text(); $host.val x.host; $port.val x.port; $name.val x.name
    $save.add($cancel).button 'disable'; false
  $spawn.click ->
    port = +$spawnPort.val()
    if !(0 < port < 0x10000)
      $.alert 'Invalid port', 'Error', -> $spawnPort.focus(); return
    else
      enableSpawnAndListen false; $spawnStatus.text 'Spawning...'; D.socket.emit '*spawn', {port}
    false
  $spawnPort.on 'keydown', null, 'return', -> $spawn.click(); false
  $listen.click ->
    port = +$listenPort.val()
    if !(0 < port < 0x10000)

    <fieldset id="spawnSection" style="display:none">
      <legend>Spawn an interpreter</legend>
      <p>
        <a href="#" id="spawn" accessKey="w">Spa<u>w</u>n</a><br>
        <span id="spawn-status"></span>
      </p>
