Software / code / prosody
Comparison
plugins/mod_register.lua @ 3540:bc139431830b
Monster whitespace commit (beware the whitespace monster).
| author | Waqas Hussain <waqas20@gmail.com> |
|---|---|
| date | Sat, 16 Oct 2010 23:00:42 +0500 |
| parent | 3529:3f9cc12308aa |
| child | 3995:e504b06492c6 |
comparison
equal
deleted
inserted
replaced
| 3539:8bbd965267b2 | 3540:bc139431830b |
|---|---|
| 149 session.send(st.error_reply(stanza, "cancel", "conflict", "The requested username already exists.")); | 149 session.send(st.error_reply(stanza, "cancel", "conflict", "The requested username already exists.")); |
| 150 else | 150 else |
| 151 if usermanager_create_user(username, password, host) then | 151 if usermanager_create_user(username, password, host) then |
| 152 session.send(st.reply(stanza)); -- user created! | 152 session.send(st.reply(stanza)); -- user created! |
| 153 module:log("info", "User account created: %s@%s", username, host); | 153 module:log("info", "User account created: %s@%s", username, host); |
| 154 module:fire_event("user-registered", { | 154 module:fire_event("user-registered", { |
| 155 username = username, host = host, source = "mod_register", | 155 username = username, host = host, source = "mod_register", |
| 156 session = session }); | 156 session = session }); |
| 157 else | 157 else |
| 158 -- TODO unable to write file, file may be locked, etc, what's the correct error? | 158 -- TODO unable to write file, file may be locked, etc, what's the correct error? |
| 159 session.send(st.error_reply(stanza, "wait", "internal-server-error", "Failed to write data to disk.")); | 159 session.send(st.error_reply(stanza, "wait", "internal-server-error", "Failed to write data to disk.")); |