]> source.dussan.org Git - nextcloud-server.git/commitdiff
confirm user is internal to globalscale 31907/head
authorMaxence Lange <maxence@artificial-owl.com>
Tue, 12 Apr 2022 10:10:41 +0000 (09:10 -0100)
committerMaxence Lange <maxence@artificial-owl.com>
Tue, 12 Apr 2022 10:11:05 +0000 (09:11 -0100)
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
lib/private/Collaboration/Collaborators/LookupPlugin.php
tests/lib/Collaboration/Collaborators/LookupPluginTest.php

index 079fd4d25752713cebbdf16830f4b0fc72bf7aa6..72cbfd4de4b88fb167bfa81bb00f752cf9ca0c7b 100644 (file)
@@ -110,6 +110,7 @@ class LookupPlugin implements ISearchPlugin {
                                        'label' => $label,
                                        'value' => [
                                                'shareType' => IShare::TYPE_REMOTE,
+                                               'globalScale' => $isGlobalScaleEnabled,
                                                'shareWith' => $lookup['federationId'],
                                        ],
                                        'extra' => $lookup,
index 3ec9e6f5efcbf8caf8ba42eb4df9eacbb1c1db32..1d856252745ac116c202e2fe2fa1df114fe8a20f 100644 (file)
@@ -303,6 +303,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[0],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => true,
                                                        'shareWith' => $fedIDs[0]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[0]],
@@ -311,6 +312,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[1],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => true,
                                                        'shareWith' => $fedIDs[1]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[1]],
@@ -319,6 +321,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[2],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => true,
                                                        'shareWith' => $fedIDs[2]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[2]],
@@ -342,6 +345,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[0],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => true,
                                                        'shareWith' => $fedIDs[0]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[0]],
@@ -350,6 +354,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[1],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => true,
                                                        'shareWith' => $fedIDs[1]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[1]],
@@ -358,6 +363,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[2],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => true,
                                                        'shareWith' => $fedIDs[2]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[2]],
@@ -381,6 +387,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[0],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => false,
                                                        'shareWith' => $fedIDs[0]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[0]],
@@ -389,6 +396,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[1],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => false,
                                                        'shareWith' => $fedIDs[1]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[1]],
@@ -397,6 +405,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[2],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => false,
                                                        'shareWith' => $fedIDs[2]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[2]],
@@ -471,6 +480,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[0],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => false,
                                                        'shareWith' => $fedIDs[0]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[0]],
@@ -479,6 +489,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[1],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => false,
                                                        'shareWith' => $fedIDs[1]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[1]],
@@ -487,6 +498,7 @@ class LookupPluginTest extends TestCase {
                                                'label' => $fedIDs[2],
                                                'value' => [
                                                        'shareType' => IShare::TYPE_REMOTE,
+                                                       'globalScale' => false,
                                                        'shareWith' => $fedIDs[2]
                                                ],
                                                'extra' => ['federationId' => $fedIDs[2]],