Skip to content

Commit

Permalink
* obby/rudel-obby.el (rudel-ask-connect-info): when extracting
Browse files Browse the repository at this point in the history
  properties from info list, there is no need to ensure info being
  non-nil
  • Loading branch information
scymtym committed Dec 19, 2009
1 parent c996c20 commit 8a56bc7
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions obby/rudel-obby.el
Expand Up @@ -99,12 +99,12 @@ connections and creates obby servers.")
&optional info)
"Ask user for the information required to connect to an obby server."
;; Read server host and port.
(let* ((host (or (and info (plist-get info :host))
(let* ((host (or (plist-get info :host)
(read-string "Server: ")))
(port (or (and info (plist-get info :port))
(port (or (plist-get info :port)
(read-number
"Port: " rudel-obby-default-port)))
(encryption (if (and info (member :encryption info))
(encryption (if (member :encryption info)
(plist-get info :encryption)
(y-or-n-p "Use encryption (Required by Gobby server, not supported by Rudel server)? ")))
(transport-backend (or (plist-get info :transport-backend)
Expand All @@ -114,14 +114,14 @@ connections and creates obby servers.")
(protocol-backend (or (plist-get info :protocol-backend)
(rudel-backend-get 'protocol 'obby)))
;; Read desired username and color
(username (or (and info (plist-get info :username))
(username (or (plist-get info :username)
(rudel-read-user-name)))
(color (or (and info (plist-get info :color))
(color (or (plist-get info :color)
(rudel-read-user-color)))
(global-password (if (and info (member :global-password info))
(global-password (if (member :global-password info)
(plist-get info :global-password)
(read-string "Global password: " "")))
(user-password (if (and info (member :user-password info))
(user-password (if (member :user-password info)
(plist-get info :user-password)
(read-string "User password: " ""))))
(append (list :transport-backend transport-backend
Expand Down

0 comments on commit 8a56bc7

Please sign in to comment.