public static function group(array $message) { self::checkClient(); $groupId = !empty($message["groupId"]); $userId = !empty($message["userId"]); self::assert($groupId && $userId, "Segment::group() expects userId and groupId"); return self::$client->group($message); }
function testEmptyArrayTraits() { $this->assertTrue(Segment::identify(array("userId" => "empty-traits", "traits" => array()))); $this->assertTrue(Segment::group(array("userId" => "empty-traits", "groupId" => "empty-traits", "traits" => array()))); }