$this->switchBoardSessionLookup[$to] = $socket;\r
\r
// Store the socket in the sessions array\r
- $intsocket = (int) $socket;\r
$this->switchBoardSessions[$to] = array(\r
'to' => $to,\r
'socket' => $socket,\r
);\r
\r
// Change the index of the session to the socket\r
+ $intsocket = (int) $socket;\r
$this->switchBoardSessions[$intsocket] = $this->switchBoardSessions[$to];\r
unset($this->switchBoardSessions[$to]);\r
\r
if (self::socketcheck($socket)) {\r
return false;\r
}\r
-\r
- if (!$this->switchBoardSessions[$to]['joined']) {\r
+ \r
+ $intsocket = (int) $socket;\r
+ if (!$this->switchBoardSessions[$intsocket]['joined']) {\r
// If our participant has not joined the session yet we can't message them!\r
return false;\r
}\r
\r
- $intsocket = (int) $socket;\r
$id = &$this->switchBoardSessions[$intsocket]['id'];\r
\r
$aMessage = $this->getMessage($Message);\r