@@ -29,104 +29,104 @@ |
||
29 | 29 | |
30 | 30 | class RemoveClassifiedEventActivity implements IRepairStep { |
31 | 31 | |
32 | - /** @var IDBConnection */ |
|
33 | - private $connection; |
|
34 | - |
|
35 | - public function __construct(IDBConnection $connection) { |
|
36 | - $this->connection = $connection; |
|
37 | - } |
|
38 | - |
|
39 | - /** |
|
40 | - * @inheritdoc |
|
41 | - */ |
|
42 | - public function getName() { |
|
43 | - return 'Remove activity entries of private events'; |
|
44 | - } |
|
45 | - |
|
46 | - /** |
|
47 | - * @inheritdoc |
|
48 | - */ |
|
49 | - public function run(IOutput $output) { |
|
50 | - if (!$this->connection->tableExists('activity')) { |
|
51 | - return; |
|
52 | - } |
|
53 | - |
|
54 | - $deletedEvents = $this->removePrivateEventActivity(); |
|
55 | - $deletedEvents += $this->removeConfidentialUncensoredEventActivity(); |
|
56 | - |
|
57 | - $output->info("Removed $deletedEvents activity entries"); |
|
58 | - } |
|
59 | - |
|
60 | - protected function removePrivateEventActivity(): int { |
|
61 | - $deletedEvents = 0; |
|
62 | - |
|
63 | - $delete = $this->connection->getQueryBuilder(); |
|
64 | - $delete->delete('activity') |
|
65 | - ->where($delete->expr()->neq('affecteduser', $delete->createParameter('owner'))) |
|
66 | - ->andWhere($delete->expr()->eq('object_type', $delete->createParameter('type'))) |
|
67 | - ->andWhere($delete->expr()->eq('object_id', $delete->createParameter('calendar_id'))) |
|
68 | - ->andWhere($delete->expr()->like('subjectparams', $delete->createParameter('event_uid'))); |
|
69 | - |
|
70 | - $query = $this->connection->getQueryBuilder(); |
|
71 | - $query->select('c.principaluri', 'o.calendarid', 'o.uid') |
|
72 | - ->from('calendarobjects', 'o') |
|
73 | - ->leftJoin('o', 'calendars', 'c', $query->expr()->eq('c.id', 'o.calendarid')) |
|
74 | - ->where($query->expr()->eq('o.classification', $query->createNamedParameter(CalDavBackend::CLASSIFICATION_PRIVATE))); |
|
75 | - $result = $query->execute(); |
|
76 | - |
|
77 | - while ($row = $result->fetch()) { |
|
78 | - if ($row['principaluri'] === null) { |
|
79 | - continue; |
|
80 | - } |
|
81 | - |
|
82 | - $delete->setParameter('owner', $this->getPrincipal($row['principaluri'])) |
|
83 | - ->setParameter('type', 'calendar') |
|
84 | - ->setParameter('calendar_id', $row['calendarid']) |
|
85 | - ->setParameter('event_uid', '%' . $this->connection->escapeLikeParameter('{"id":"' . $row['uid'] . '"') . '%'); |
|
86 | - $deletedEvents += $delete->execute(); |
|
87 | - } |
|
88 | - $result->closeCursor(); |
|
89 | - |
|
90 | - return $deletedEvents; |
|
91 | - } |
|
92 | - |
|
93 | - protected function removeConfidentialUncensoredEventActivity(): int { |
|
94 | - $deletedEvents = 0; |
|
95 | - |
|
96 | - $delete = $this->connection->getQueryBuilder(); |
|
97 | - $delete->delete('activity') |
|
98 | - ->where($delete->expr()->neq('affecteduser', $delete->createParameter('owner'))) |
|
99 | - ->andWhere($delete->expr()->eq('object_type', $delete->createParameter('type'))) |
|
100 | - ->andWhere($delete->expr()->eq('object_id', $delete->createParameter('calendar_id'))) |
|
101 | - ->andWhere($delete->expr()->like('subjectparams', $delete->createParameter('event_uid'))) |
|
102 | - ->andWhere($delete->expr()->notLike('subjectparams', $delete->createParameter('filtered_name'))); |
|
103 | - |
|
104 | - $query = $this->connection->getQueryBuilder(); |
|
105 | - $query->select('c.principaluri', 'o.calendarid', 'o.uid') |
|
106 | - ->from('calendarobjects', 'o') |
|
107 | - ->leftJoin('o', 'calendars', 'c', $query->expr()->eq('c.id', 'o.calendarid')) |
|
108 | - ->where($query->expr()->eq('o.classification', $query->createNamedParameter(CalDavBackend::CLASSIFICATION_CONFIDENTIAL))); |
|
109 | - $result = $query->execute(); |
|
110 | - |
|
111 | - while ($row = $result->fetch()) { |
|
112 | - if ($row['principaluri'] === null) { |
|
113 | - continue; |
|
114 | - } |
|
115 | - |
|
116 | - $delete->setParameter('owner', $this->getPrincipal($row['principaluri'])) |
|
117 | - ->setParameter('type', 'calendar') |
|
118 | - ->setParameter('calendar_id', $row['calendarid']) |
|
119 | - ->setParameter('event_uid', '%' . $this->connection->escapeLikeParameter('{"id":"' . $row['uid'] . '"') . '%') |
|
120 | - ->setParameter('filtered_name', '%' . $this->connection->escapeLikeParameter('{"id":"' . $row['uid'] . '","name":"Busy"') . '%'); |
|
121 | - $deletedEvents += $delete->execute(); |
|
122 | - } |
|
123 | - $result->closeCursor(); |
|
124 | - |
|
125 | - return $deletedEvents; |
|
126 | - } |
|
127 | - |
|
128 | - protected function getPrincipal(string $principalUri): string { |
|
129 | - $uri = explode('/', $principalUri); |
|
130 | - return array_pop($uri); |
|
131 | - } |
|
32 | + /** @var IDBConnection */ |
|
33 | + private $connection; |
|
34 | + |
|
35 | + public function __construct(IDBConnection $connection) { |
|
36 | + $this->connection = $connection; |
|
37 | + } |
|
38 | + |
|
39 | + /** |
|
40 | + * @inheritdoc |
|
41 | + */ |
|
42 | + public function getName() { |
|
43 | + return 'Remove activity entries of private events'; |
|
44 | + } |
|
45 | + |
|
46 | + /** |
|
47 | + * @inheritdoc |
|
48 | + */ |
|
49 | + public function run(IOutput $output) { |
|
50 | + if (!$this->connection->tableExists('activity')) { |
|
51 | + return; |
|
52 | + } |
|
53 | + |
|
54 | + $deletedEvents = $this->removePrivateEventActivity(); |
|
55 | + $deletedEvents += $this->removeConfidentialUncensoredEventActivity(); |
|
56 | + |
|
57 | + $output->info("Removed $deletedEvents activity entries"); |
|
58 | + } |
|
59 | + |
|
60 | + protected function removePrivateEventActivity(): int { |
|
61 | + $deletedEvents = 0; |
|
62 | + |
|
63 | + $delete = $this->connection->getQueryBuilder(); |
|
64 | + $delete->delete('activity') |
|
65 | + ->where($delete->expr()->neq('affecteduser', $delete->createParameter('owner'))) |
|
66 | + ->andWhere($delete->expr()->eq('object_type', $delete->createParameter('type'))) |
|
67 | + ->andWhere($delete->expr()->eq('object_id', $delete->createParameter('calendar_id'))) |
|
68 | + ->andWhere($delete->expr()->like('subjectparams', $delete->createParameter('event_uid'))); |
|
69 | + |
|
70 | + $query = $this->connection->getQueryBuilder(); |
|
71 | + $query->select('c.principaluri', 'o.calendarid', 'o.uid') |
|
72 | + ->from('calendarobjects', 'o') |
|
73 | + ->leftJoin('o', 'calendars', 'c', $query->expr()->eq('c.id', 'o.calendarid')) |
|
74 | + ->where($query->expr()->eq('o.classification', $query->createNamedParameter(CalDavBackend::CLASSIFICATION_PRIVATE))); |
|
75 | + $result = $query->execute(); |
|
76 | + |
|
77 | + while ($row = $result->fetch()) { |
|
78 | + if ($row['principaluri'] === null) { |
|
79 | + continue; |
|
80 | + } |
|
81 | + |
|
82 | + $delete->setParameter('owner', $this->getPrincipal($row['principaluri'])) |
|
83 | + ->setParameter('type', 'calendar') |
|
84 | + ->setParameter('calendar_id', $row['calendarid']) |
|
85 | + ->setParameter('event_uid', '%' . $this->connection->escapeLikeParameter('{"id":"' . $row['uid'] . '"') . '%'); |
|
86 | + $deletedEvents += $delete->execute(); |
|
87 | + } |
|
88 | + $result->closeCursor(); |
|
89 | + |
|
90 | + return $deletedEvents; |
|
91 | + } |
|
92 | + |
|
93 | + protected function removeConfidentialUncensoredEventActivity(): int { |
|
94 | + $deletedEvents = 0; |
|
95 | + |
|
96 | + $delete = $this->connection->getQueryBuilder(); |
|
97 | + $delete->delete('activity') |
|
98 | + ->where($delete->expr()->neq('affecteduser', $delete->createParameter('owner'))) |
|
99 | + ->andWhere($delete->expr()->eq('object_type', $delete->createParameter('type'))) |
|
100 | + ->andWhere($delete->expr()->eq('object_id', $delete->createParameter('calendar_id'))) |
|
101 | + ->andWhere($delete->expr()->like('subjectparams', $delete->createParameter('event_uid'))) |
|
102 | + ->andWhere($delete->expr()->notLike('subjectparams', $delete->createParameter('filtered_name'))); |
|
103 | + |
|
104 | + $query = $this->connection->getQueryBuilder(); |
|
105 | + $query->select('c.principaluri', 'o.calendarid', 'o.uid') |
|
106 | + ->from('calendarobjects', 'o') |
|
107 | + ->leftJoin('o', 'calendars', 'c', $query->expr()->eq('c.id', 'o.calendarid')) |
|
108 | + ->where($query->expr()->eq('o.classification', $query->createNamedParameter(CalDavBackend::CLASSIFICATION_CONFIDENTIAL))); |
|
109 | + $result = $query->execute(); |
|
110 | + |
|
111 | + while ($row = $result->fetch()) { |
|
112 | + if ($row['principaluri'] === null) { |
|
113 | + continue; |
|
114 | + } |
|
115 | + |
|
116 | + $delete->setParameter('owner', $this->getPrincipal($row['principaluri'])) |
|
117 | + ->setParameter('type', 'calendar') |
|
118 | + ->setParameter('calendar_id', $row['calendarid']) |
|
119 | + ->setParameter('event_uid', '%' . $this->connection->escapeLikeParameter('{"id":"' . $row['uid'] . '"') . '%') |
|
120 | + ->setParameter('filtered_name', '%' . $this->connection->escapeLikeParameter('{"id":"' . $row['uid'] . '","name":"Busy"') . '%'); |
|
121 | + $deletedEvents += $delete->execute(); |
|
122 | + } |
|
123 | + $result->closeCursor(); |
|
124 | + |
|
125 | + return $deletedEvents; |
|
126 | + } |
|
127 | + |
|
128 | + protected function getPrincipal(string $principalUri): string { |
|
129 | + $uri = explode('/', $principalUri); |
|
130 | + return array_pop($uri); |
|
131 | + } |
|
132 | 132 | } |
@@ -32,68 +32,68 @@ |
||
32 | 32 | */ |
33 | 33 | interface ISubAdmin { |
34 | 34 | |
35 | - /** |
|
36 | - * add a SubAdmin |
|
37 | - * @param IUser $user user to be SubAdmin |
|
38 | - * @param IGroup $group group $user becomes subadmin of |
|
39 | - * |
|
40 | - * @since 16.0.0 |
|
41 | - */ |
|
42 | - public function createSubAdmin(IUser $user, IGroup $group): void; |
|
35 | + /** |
|
36 | + * add a SubAdmin |
|
37 | + * @param IUser $user user to be SubAdmin |
|
38 | + * @param IGroup $group group $user becomes subadmin of |
|
39 | + * |
|
40 | + * @since 16.0.0 |
|
41 | + */ |
|
42 | + public function createSubAdmin(IUser $user, IGroup $group): void; |
|
43 | 43 | |
44 | - /** |
|
45 | - * delete a SubAdmin |
|
46 | - * @param IUser $user the user that is the SubAdmin |
|
47 | - * @param IGroup $group the group |
|
48 | - * |
|
49 | - * @since 16.0.0 |
|
50 | - */ |
|
51 | - public function deleteSubAdmin(IUser $user, IGroup $group): void; |
|
44 | + /** |
|
45 | + * delete a SubAdmin |
|
46 | + * @param IUser $user the user that is the SubAdmin |
|
47 | + * @param IGroup $group the group |
|
48 | + * |
|
49 | + * @since 16.0.0 |
|
50 | + */ |
|
51 | + public function deleteSubAdmin(IUser $user, IGroup $group): void; |
|
52 | 52 | |
53 | - /** |
|
54 | - * get groups of a SubAdmin |
|
55 | - * @param IUser $user the SubAdmin |
|
56 | - * @return IGroup[] |
|
57 | - * |
|
58 | - * @since 16.0.0 |
|
59 | - */ |
|
60 | - public function getSubAdminsGroups(IUser $user): array; |
|
53 | + /** |
|
54 | + * get groups of a SubAdmin |
|
55 | + * @param IUser $user the SubAdmin |
|
56 | + * @return IGroup[] |
|
57 | + * |
|
58 | + * @since 16.0.0 |
|
59 | + */ |
|
60 | + public function getSubAdminsGroups(IUser $user): array; |
|
61 | 61 | |
62 | - /** |
|
63 | - * get SubAdmins of a group |
|
64 | - * @param IGroup $group the group |
|
65 | - * @return IUser[] |
|
66 | - * |
|
67 | - * @since 16.0.0 |
|
68 | - */ |
|
69 | - public function getGroupsSubAdmins(IGroup $group): array; |
|
62 | + /** |
|
63 | + * get SubAdmins of a group |
|
64 | + * @param IGroup $group the group |
|
65 | + * @return IUser[] |
|
66 | + * |
|
67 | + * @since 16.0.0 |
|
68 | + */ |
|
69 | + public function getGroupsSubAdmins(IGroup $group): array; |
|
70 | 70 | |
71 | - /** |
|
72 | - * checks if a user is a SubAdmin of a group |
|
73 | - * @param IUser $user |
|
74 | - * @param IGroup $group |
|
75 | - * @return bool |
|
76 | - * |
|
77 | - * @since 16.0.0 |
|
78 | - */ |
|
79 | - public function isSubAdminOfGroup(IUser $user, IGroup $group): bool; |
|
71 | + /** |
|
72 | + * checks if a user is a SubAdmin of a group |
|
73 | + * @param IUser $user |
|
74 | + * @param IGroup $group |
|
75 | + * @return bool |
|
76 | + * |
|
77 | + * @since 16.0.0 |
|
78 | + */ |
|
79 | + public function isSubAdminOfGroup(IUser $user, IGroup $group): bool; |
|
80 | 80 | |
81 | - /** |
|
82 | - * checks if a user is a SubAdmin |
|
83 | - * @param IUser $user |
|
84 | - * @return bool |
|
85 | - * |
|
86 | - * @since 16.0.0 |
|
87 | - */ |
|
88 | - public function isSubAdmin(IUser $user): bool; |
|
81 | + /** |
|
82 | + * checks if a user is a SubAdmin |
|
83 | + * @param IUser $user |
|
84 | + * @return bool |
|
85 | + * |
|
86 | + * @since 16.0.0 |
|
87 | + */ |
|
88 | + public function isSubAdmin(IUser $user): bool; |
|
89 | 89 | |
90 | - /** |
|
91 | - * checks if a user is a accessible by a subadmin |
|
92 | - * @param IUser $subadmin |
|
93 | - * @param IUser $user |
|
94 | - * @return bool |
|
95 | - * |
|
96 | - * @since 16.0.0 |
|
97 | - */ |
|
98 | - public function isUserAccessible(IUser $subadmin, IUser $user): bool; |
|
90 | + /** |
|
91 | + * checks if a user is a accessible by a subadmin |
|
92 | + * @param IUser $subadmin |
|
93 | + * @param IUser $user |
|
94 | + * @return bool |
|
95 | + * |
|
96 | + * @since 16.0.0 |
|
97 | + */ |
|
98 | + public function isUserAccessible(IUser $subadmin, IUser $user): bool; |
|
99 | 99 | } |
@@ -28,8 +28,8 @@ |
||
28 | 28 | use OCP\Template; |
29 | 29 | |
30 | 30 | class Personal implements IPersonalProviderSettings { |
31 | - public function getBody(): Template { |
|
32 | - return new Template('twofactor_backupcodes', 'personal'); |
|
33 | - } |
|
31 | + public function getBody(): Template { |
|
32 | + return new Template('twofactor_backupcodes', 'personal'); |
|
33 | + } |
|
34 | 34 | |
35 | 35 | } |
@@ -35,34 +35,34 @@ |
||
35 | 35 | * a reload but if the session variable is set we properly redirect to the login page. |
36 | 36 | */ |
37 | 37 | class ReloadExecutionMiddleware extends Middleware { |
38 | - /** @var ISession */ |
|
39 | - private $session; |
|
40 | - /** @var IURLGenerator */ |
|
41 | - private $urlGenerator; |
|
38 | + /** @var ISession */ |
|
39 | + private $session; |
|
40 | + /** @var IURLGenerator */ |
|
41 | + private $urlGenerator; |
|
42 | 42 | |
43 | - public function __construct(ISession $session, IURLGenerator $urlGenerator) { |
|
44 | - $this->session = $session; |
|
45 | - $this->urlGenerator = $urlGenerator; |
|
46 | - } |
|
43 | + public function __construct(ISession $session, IURLGenerator $urlGenerator) { |
|
44 | + $this->session = $session; |
|
45 | + $this->urlGenerator = $urlGenerator; |
|
46 | + } |
|
47 | 47 | |
48 | - public function beforeController($controller, $methodName) { |
|
49 | - if ($this->session->exists('clearingExecutionContexts')) { |
|
50 | - throw new ReloadExecutionException(); |
|
51 | - } |
|
52 | - } |
|
48 | + public function beforeController($controller, $methodName) { |
|
49 | + if ($this->session->exists('clearingExecutionContexts')) { |
|
50 | + throw new ReloadExecutionException(); |
|
51 | + } |
|
52 | + } |
|
53 | 53 | |
54 | - public function afterException($controller, $methodName, \Exception $exception) { |
|
55 | - if ($exception instanceof ReloadExecutionException) { |
|
56 | - $this->session->remove('clearingExecutionContexts'); |
|
54 | + public function afterException($controller, $methodName, \Exception $exception) { |
|
55 | + if ($exception instanceof ReloadExecutionException) { |
|
56 | + $this->session->remove('clearingExecutionContexts'); |
|
57 | 57 | |
58 | - return new RedirectResponse($this->urlGenerator->linkToRouteAbsolute( |
|
59 | - 'core.login.showLoginForm', |
|
60 | - ['clear' => true] // this param the the code in login.js may be removed when the "Clear-Site-Data" is working in the browsers |
|
61 | - )); |
|
62 | - } |
|
58 | + return new RedirectResponse($this->urlGenerator->linkToRouteAbsolute( |
|
59 | + 'core.login.showLoginForm', |
|
60 | + ['clear' => true] // this param the the code in login.js may be removed when the "Clear-Site-Data" is working in the browsers |
|
61 | + )); |
|
62 | + } |
|
63 | 63 | |
64 | - return parent::afterException($controller, $methodName, $exception); |
|
65 | - } |
|
64 | + return parent::afterException($controller, $methodName, $exception); |
|
65 | + } |
|
66 | 66 | |
67 | 67 | |
68 | 68 | } |
@@ -34,24 +34,24 @@ |
||
34 | 34 | |
35 | 35 | interface IAvatarManager { |
36 | 36 | |
37 | - /** |
|
38 | - * return a user specific instance of \OCP\IAvatar |
|
39 | - * @see IAvatar |
|
40 | - * @param string $user the ownCloud user id |
|
41 | - * @return IAvatar |
|
42 | - * @throws \Exception In case the username is potentially dangerous |
|
43 | - * @throws \OCP\Files\NotFoundException In case there is no user folder yet |
|
44 | - * @since 6.0.0 |
|
45 | - */ |
|
46 | - public function getAvatar(string $user) : IAvatar; |
|
37 | + /** |
|
38 | + * return a user specific instance of \OCP\IAvatar |
|
39 | + * @see IAvatar |
|
40 | + * @param string $user the ownCloud user id |
|
41 | + * @return IAvatar |
|
42 | + * @throws \Exception In case the username is potentially dangerous |
|
43 | + * @throws \OCP\Files\NotFoundException In case there is no user folder yet |
|
44 | + * @since 6.0.0 |
|
45 | + */ |
|
46 | + public function getAvatar(string $user) : IAvatar; |
|
47 | 47 | |
48 | - /** |
|
49 | - * Returns a guest user avatar instance. |
|
50 | - * |
|
51 | - * @param string $name The guest name, e.g. "Albert". |
|
52 | - * @return IAvatar |
|
53 | - * @since 16.0.0 |
|
54 | - */ |
|
55 | - public function getGuestAvatar(string $name): IAvatar; |
|
48 | + /** |
|
49 | + * Returns a guest user avatar instance. |
|
50 | + * |
|
51 | + * @param string $name The guest name, e.g. "Albert". |
|
52 | + * @return IAvatar |
|
53 | + * @since 16.0.0 |
|
54 | + */ |
|
55 | + public function getGuestAvatar(string $name): IAvatar; |
|
56 | 56 | |
57 | 57 | } |
@@ -30,10 +30,10 @@ |
||
30 | 30 | * @since 16.0.0 |
31 | 31 | */ |
32 | 32 | interface IConfigHandler { |
33 | - /** |
|
34 | - * @param mixed $optionValue |
|
35 | - * @return mixed the same type as $optionValue |
|
36 | - * @since 16.0.0 |
|
37 | - */ |
|
38 | - public function handle($optionValue); |
|
33 | + /** |
|
34 | + * @param mixed $optionValue |
|
35 | + * @return mixed the same type as $optionValue |
|
36 | + * @since 16.0.0 |
|
37 | + */ |
|
38 | + public function handle($optionValue); |
|
39 | 39 | } |
@@ -28,38 +28,38 @@ |
||
28 | 28 | |
29 | 29 | class Capabilities implements ICapability { |
30 | 30 | |
31 | - /** @var IURLGenerator */ |
|
32 | - private $urlGenerator; |
|
31 | + /** @var IURLGenerator */ |
|
32 | + private $urlGenerator; |
|
33 | 33 | |
34 | - public function __construct(IURLGenerator $urlGenerator) { |
|
35 | - $this->urlGenerator = $urlGenerator; |
|
36 | - } |
|
34 | + public function __construct(IURLGenerator $urlGenerator) { |
|
35 | + $this->urlGenerator = $urlGenerator; |
|
36 | + } |
|
37 | 37 | |
38 | - /** |
|
39 | - * Function an app uses to return the capabilities |
|
40 | - * |
|
41 | - * @return array Array containing the apps capabilities |
|
42 | - * @since 8.2.0 |
|
43 | - */ |
|
44 | - public function getCapabilities() { |
|
45 | - $url = $this->urlGenerator->linkToRouteAbsolute('cloud_federation_api.requesthandlercontroller.addShare'); |
|
46 | - $capabilities = ['ocm' => |
|
47 | - [ |
|
48 | - 'enabled' => true, |
|
49 | - 'apiVersion' => '1.0-proposal1', |
|
50 | - 'endPoint' => substr($url, 0, strrpos($url, '/')), |
|
51 | - 'resourceTypes' => [ |
|
52 | - [ |
|
53 | - 'name' => 'file', |
|
54 | - 'shareTypes' => ['user', 'group'], |
|
55 | - 'protocols' => [ |
|
56 | - 'webdav' => '/public.php/webdav/', |
|
57 | - ] |
|
58 | - ], |
|
59 | - ] |
|
60 | - ] |
|
61 | - ]; |
|
38 | + /** |
|
39 | + * Function an app uses to return the capabilities |
|
40 | + * |
|
41 | + * @return array Array containing the apps capabilities |
|
42 | + * @since 8.2.0 |
|
43 | + */ |
|
44 | + public function getCapabilities() { |
|
45 | + $url = $this->urlGenerator->linkToRouteAbsolute('cloud_federation_api.requesthandlercontroller.addShare'); |
|
46 | + $capabilities = ['ocm' => |
|
47 | + [ |
|
48 | + 'enabled' => true, |
|
49 | + 'apiVersion' => '1.0-proposal1', |
|
50 | + 'endPoint' => substr($url, 0, strrpos($url, '/')), |
|
51 | + 'resourceTypes' => [ |
|
52 | + [ |
|
53 | + 'name' => 'file', |
|
54 | + 'shareTypes' => ['user', 'group'], |
|
55 | + 'protocols' => [ |
|
56 | + 'webdav' => '/public.php/webdav/', |
|
57 | + ] |
|
58 | + ], |
|
59 | + ] |
|
60 | + ] |
|
61 | + ]; |
|
62 | 62 | |
63 | - return $capabilities; |
|
64 | - } |
|
63 | + return $capabilities; |
|
64 | + } |
|
65 | 65 | } |
@@ -31,19 +31,19 @@ |
||
31 | 31 | |
32 | 32 | class AddClenupLoginFlowV2BackgroundJob implements IRepairStep { |
33 | 33 | |
34 | - /** @var IJobList */ |
|
35 | - private $jobList; |
|
34 | + /** @var IJobList */ |
|
35 | + private $jobList; |
|
36 | 36 | |
37 | - public function __construct(IJobList $jobList) { |
|
38 | - $this->jobList = $jobList; |
|
39 | - } |
|
37 | + public function __construct(IJobList $jobList) { |
|
38 | + $this->jobList = $jobList; |
|
39 | + } |
|
40 | 40 | |
41 | - public function getName(): string { |
|
42 | - return 'Add background job to cleanup login flow v2 tokens'; |
|
43 | - } |
|
41 | + public function getName(): string { |
|
42 | + return 'Add background job to cleanup login flow v2 tokens'; |
|
43 | + } |
|
44 | 44 | |
45 | - public function run(IOutput $output) { |
|
46 | - $this->jobList->add(CleanupLoginFlowV2::class); |
|
47 | - } |
|
45 | + public function run(IOutput $output) { |
|
46 | + $this->jobList->add(CleanupLoginFlowV2::class); |
|
47 | + } |
|
48 | 48 | |
49 | 49 | } |
@@ -25,47 +25,47 @@ |
||
25 | 25 | namespace OC\Core\Data; |
26 | 26 | |
27 | 27 | class LoginFlowV2Credentials implements \JsonSerializable { |
28 | - /** @var string */ |
|
29 | - private $server; |
|
30 | - /** @var string */ |
|
31 | - private $loginName; |
|
32 | - /** @var string */ |
|
33 | - private $appPassword; |
|
28 | + /** @var string */ |
|
29 | + private $server; |
|
30 | + /** @var string */ |
|
31 | + private $loginName; |
|
32 | + /** @var string */ |
|
33 | + private $appPassword; |
|
34 | 34 | |
35 | - public function __construct(string $server, string $loginName, string $appPassword) { |
|
36 | - $this->server = $server; |
|
37 | - $this->loginName = $loginName; |
|
38 | - $this->appPassword = $appPassword; |
|
39 | - } |
|
35 | + public function __construct(string $server, string $loginName, string $appPassword) { |
|
36 | + $this->server = $server; |
|
37 | + $this->loginName = $loginName; |
|
38 | + $this->appPassword = $appPassword; |
|
39 | + } |
|
40 | 40 | |
41 | - /** |
|
42 | - * @return string |
|
43 | - */ |
|
44 | - public function getServer(): string { |
|
45 | - return $this->server; |
|
46 | - } |
|
41 | + /** |
|
42 | + * @return string |
|
43 | + */ |
|
44 | + public function getServer(): string { |
|
45 | + return $this->server; |
|
46 | + } |
|
47 | 47 | |
48 | - /** |
|
49 | - * @return string |
|
50 | - */ |
|
51 | - public function getLoginName(): string { |
|
52 | - return $this->loginName; |
|
53 | - } |
|
48 | + /** |
|
49 | + * @return string |
|
50 | + */ |
|
51 | + public function getLoginName(): string { |
|
52 | + return $this->loginName; |
|
53 | + } |
|
54 | 54 | |
55 | - /** |
|
56 | - * @return string |
|
57 | - */ |
|
58 | - public function getAppPassword(): string { |
|
59 | - return $this->appPassword; |
|
60 | - } |
|
55 | + /** |
|
56 | + * @return string |
|
57 | + */ |
|
58 | + public function getAppPassword(): string { |
|
59 | + return $this->appPassword; |
|
60 | + } |
|
61 | 61 | |
62 | - public function jsonSerialize(): array { |
|
63 | - return [ |
|
64 | - 'server' => $this->server, |
|
65 | - 'loginName' => $this->loginName, |
|
66 | - 'appPassword' => $this->appPassword, |
|
67 | - ]; |
|
68 | - } |
|
62 | + public function jsonSerialize(): array { |
|
63 | + return [ |
|
64 | + 'server' => $this->server, |
|
65 | + 'loginName' => $this->loginName, |
|
66 | + 'appPassword' => $this->appPassword, |
|
67 | + ]; |
|
68 | + } |
|
69 | 69 | |
70 | 70 | |
71 | 71 | } |