From 007f1b443888a17b5156ef871e5548d28a3a0130 Mon Sep 17 00:00:00 2001
From: Thomas Bruederli <thomas@roundcube.net>
Date: Sun, 20 Jul 2014 08:00:58 -0400
Subject: [PATCH] Warn for unsent/unsaved message when closing compose window; remove localStorage copy if page was left intentionally but not on session errors (#1489818)

---
 index.php |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/index.php b/index.php
index 4763501..a1e957d 100644
--- a/index.php
+++ b/index.php
@@ -211,7 +211,7 @@
         $OUTPUT->show_message('sessionerror', 'error', null, true, -1);
     }
 
-    if ($OUTPUT->ajax_call || !empty($_REQUEST['_framed'])) {
+    if ($OUTPUT->ajax_call || $OUTPUT->get_env('framed')) {
         $OUTPUT->command('session_error', $RCMAIL->url(array('_err' => 'session')));
         $OUTPUT->send('iframe');
     }

--
Gitblit v1.9.1