Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2020-10-14 12:47:02 +0300
committerJoas Schilling <coding@schilljs.com>2020-10-14 14:39:44 +0300
commitb5dcc26c932fafa27cf380a2a9c2890abe38751f (patch)
tree8979aadd0f8864d547179120b87181e1d7c940ce /lib
parent473535ba268a763ba2325d023d928e99f85c5e09 (diff)
Fix entropy calculation and missing default values for lobby
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/Controller/RoomController.php4
-rw-r--r--lib/Manager.php2
2 files changed, 5 insertions, 1 deletions
diff --git a/lib/Controller/RoomController.php b/lib/Controller/RoomController.php
index b8f517d86..af8d6a9e9 100644
--- a/lib/Controller/RoomController.php
+++ b/lib/Controller/RoomController.php
@@ -265,6 +265,8 @@ class RoomController extends AEnvironmentAwareController {
'unreadMention' => false,
'isFavorite' => false,
'notificationLevel' => Participant::NOTIFY_NEVER,
+ 'lobbyState' => Webinary::LOBBY_NONE,
+ 'lobbyTimer' => 0,
'lastPing' => 0,
'sessionId' => '0',
'participants' => [],
@@ -441,6 +443,8 @@ class RoomController extends AEnvironmentAwareController {
'canLeaveConversation' => false,
'canDeleteConversation' => false,
'notificationLevel' => Participant::NOTIFY_NEVER,
+ 'lobbyState' => Webinary::LOBBY_NONE,
+ 'lobbyTimer' => 0,
'lastPing' => 0,
'sessionId' => '0',
'guestList' => '',
diff --git a/lib/Manager.php b/lib/Manager.php
index d372f8fd8..5a4b81eb7 100644
--- a/lib/Manager.php
+++ b/lib/Manager.php
@@ -806,7 +806,7 @@ class Manager {
protected function getNewToken(): string {
$chars = str_replace(['l', '0', '1'], '', ISecureRandom::CHAR_LOWER . ISecureRandom::CHAR_DIGITS);
$entropy = (int) $this->config->getAppValue('spreed', 'token_entropy', 8);
- $entropy = min(8, $entropy); // For update cases
+ $entropy = max(8, $entropy); // For update cases
$query = $this->db->getQueryBuilder();
$query->select('id')