summaryrefslogtreecommitdiff
path: root/program/steps/addressbook
diff options
context:
space:
mode:
authoralecpl <alec@alec.pl>2011-08-02 10:57:35 +0000
committeralecpl <alec@alec.pl>2011-08-02 10:57:35 +0000
commit2dd2bf5012825b68612353ccb141d6b6a0bc61aa (patch)
tree347bf1624b41fda28c033d9eedcae01af1bef997 /program/steps/addressbook
parent46285d4b56c55dfe6c5a24e3b6d24db608873726 (diff)
- Fixed form reloading on source change, broken in r4999
Diffstat (limited to 'program/steps/addressbook')
-rw-r--r--program/steps/addressbook/save.inc6
1 files changed, 6 insertions, 0 deletions
diff --git a/program/steps/addressbook/save.inc b/program/steps/addressbook/save.inc
index 43426d8f3..24b1a5da3 100644
--- a/program/steps/addressbook/save.inc
+++ b/program/steps/addressbook/save.inc
@@ -23,6 +23,12 @@ $CONTACTS = rcmail_contact_source(null, true, true);
$cid = get_input_value('_cid', RCUBE_INPUT_POST);
$return_action = empty($cid) ? 'add' : 'edit';
+// Source changed, display the form again
+if (!empty($_GET['_reload'])) {
+ rcmail_overwrite_action($return_action);
+ return;
+}
+
// cannot edit record
if ($CONTACTS->readonly) {
$OUTPUT->show_message('contactreadonly', 'error');