[imp] Lost recomposed message after logging out
Janne Peltonen
janne.peltonen at helsinki.fi
Tue Dec 2 09:19:16 UTC 2008
On Tue, Dec 02, 2008 at 01:34:01AM -0700, Sean Coleman wrote:
> Several people have asked why messages being composed and not sent get
> lost if the
> user was logged out. In older versions of imp, the software would let
> the user know that
> a message was being composed when logged out and bring back the
> composition window
> with the text of the message as it was when the user was logged out.
>
> I have figured out the reason why the new software no longer behaves in
> this manner. Line 53 of
> imp/lib/base.php has the following line:
>
> $compose_page = (isset($_SESSION['imp']['viewmode']) &&
> $_SESSION['imp']['viewmode'] == 'imp') && strstr($_SERVER['PHP_SELF'],
> 'compose.php');$compose_page = (isset($_SESSION['imp']['viewmode']) &&
> $_SESSION['imp']['viewmode'] == 'imp') && strstr($_SERVER['PHP_SELF'],
> 'compose.php');
>
>
> $compose_page will always be false when a user logs out since
> $_SESSION['imp'] will be NULL, therefore
> the $RECOMPOSE variable will never get set to true on lines 102 and 122.
> Since $RECOMPOSE is never
> set to TRUE, the code to display the current composed message will never
> happen.
>
> I hope this helps in resolving the issue.
I can confirm this bug. (I have a faint idea that I did report it a
while back, but maybe I didn't, since I'm unable to find it in the bug
tracking system.) Anyway, we resolved it simply by not caring about the
viewmode if it was null...
--Janne Peltonen
Univ of Helsinki
--
Janne Peltonen <janne.peltonen at helsinki.fi> PGP Key ID: 0x9CFAC88B
Please consider membership of the Hospitality Club (http://www.hospitalityclub.org)
More information about the imp
mailing list