[Phpfreechat-svn] SF.net SVN: phpfreechat: [1220] trunk/src/commands/connect.class.php
Status: Beta
Brought to you by:
kerphi
From: <ke...@us...> - 2007-11-25 21:51:14
|
Revision: 1220 http://phpfreechat.svn.sourceforge.net/phpfreechat/?rev=1220&view=rev Author: kerphi Date: 2007-11-25 13:51:18 -0800 (Sun, 25 Nov 2007) Log Message: ----------- Bug fix: when max_msg value was zero, no message should be displayed at first chat loading (thanks to lnevo) Modified Paths: -------------- trunk/src/commands/connect.class.php Modified: trunk/src/commands/connect.class.php =================================================================== --- trunk/src/commands/connect.class.php 2007-11-25 21:48:09 UTC (rev 1219) +++ trunk/src/commands/connect.class.php 2007-11-25 21:51:18 UTC (rev 1220) @@ -110,7 +110,7 @@ $chanid = pfcCommand_join::GetRecipientId($channame); // reset the fromid flag $from_id_sid = "pfc_from_id_".$c->getId()."_".$clientid."_".$chanid; - $from_id = $ct->getLastId($chanrecip)-$c->max_msg; + $from_id = $ct->getLastId($chanrecip)-$c->max_msg+1; $_SESSION[$from_id_sid] = ($from_id<0) ? 0 : $from_id; // reset the oldmsg flag $oldmsg_sid = "pfc_oldmsg_".$c->getId()."_".$clientid."_".$chanid; @@ -124,7 +124,7 @@ $recipient2 = $pv['recipient']; // reset the fromid flag $from_id_sid = "pfc_from_id_".$c->getId()."_".$clientid."_".$recipientid2; - $from_id = $ct->getLastId($recipient2)-$c->max_msg; + $from_id = $ct->getLastId($recipient2)-$c->max_msg+1; $_SESSION[$from_id_sid] = ($from_id<0) ? 0 : $from_id; // reset the oldmsg flag $oldmsg_sid = "pfc_oldmsg_".$c->getId()."_".$clientid."_".$recipientid2; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |