ponymail-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject incubator-ponymail git commit: Allow for extraneous embedded null
Date Sat, 17 Dec 2016 21:15:54 GMT
Repository: incubator-ponymail
Updated Branches:
  refs/heads/master 9ce995e26 -> 575200eff


Allow for extraneous embedded null

Project: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/commit/575200ef
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/tree/575200ef
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/diff/575200ef

Branch: refs/heads/master
Commit: 575200eff272046cd63011badd5aecdac03c46a2
Parents: 9ce995e
Author: Sebb <sebb@apache.org>
Authored: Sat Dec 17 21:15:38 2016 +0000
Committer: Sebb <sebb@apache.org>
Committed: Sat Dec 17 21:15:38 2016 +0000

----------------------------------------------------------------------
 site/api/preferences.lua | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ponymail/blob/575200ef/site/api/preferences.lua
----------------------------------------------------------------------
diff --git a/site/api/preferences.lua b/site/api/preferences.lua
index 54a6834..70ae8be 100644
--- a/site/api/preferences.lua
+++ b/site/api/preferences.lua
@@ -149,7 +149,8 @@ Pony Mail - Email for Ponies and People.
     -- remove alt email?
     if get.removealt and account and account.credentials.altemail then
         for k, v in pairs(account.credentials.altemail) do
-            if v.email == get.removealt then
+            -- allow for null just in case table was corrupted
+            if v == JSON.null or v.email == get.removealt then
                 table.remove(account.credentials.altemail, k)
                 break
             end


Mime
View raw message