diff options
author | Waqas Hussain <waqas20@gmail.com> | 2010-05-23 23:55:01 +0500 |
---|---|---|
committer | Waqas Hussain <waqas20@gmail.com> | 2010-05-23 23:55:01 +0500 |
commit | 42f63b21d79733a2198952245df0673434bd31d2 (patch) | |
tree | c0744d7d2cdf6326310ce56b7545f0931dcc31d8 /util/datamanager.lua | |
parent | 8abd2f2c24bd83acb36e9c8ace40ac3751f09663 (diff) | |
download | prosody-42f63b21d79733a2198952245df0673434bd31d2.tar.gz prosody-42f63b21d79733a2198952245df0673434bd31d2.zip |
util.datamanager: Return an error string when failing to save.
Diffstat (limited to 'util/datamanager.lua')
-rw-r--r-- | util/datamanager.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/util/datamanager.lua b/util/datamanager.lua index 9d96e5b3..57cd2594 100644 --- a/util/datamanager.lua +++ b/util/datamanager.lua @@ -145,7 +145,7 @@ function store(username, host, datastore, data) local f, msg = io_open(getpath(username, host, datastore, nil, true), "w+"); if not f then log("error", "Unable to write to "..datastore.." storage ('"..msg.."') for user: "..(username or "nil").."@"..(host or "nil")); - return; + return nil, "Error saving to storage"; end f:write("return "); append(f, data); |