Browse Source

we don't need to remove the job manually here, even if we ask once more the other server will decline and the background job will be removed

Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
tags/v13.0.0beta1
Bjoern Schiessle 6 years ago
parent
commit
3ffff08819
No account linked to committer's email address

+ 0
- 9
apps/federation/lib/Controller/OCSAuthAPIController.php View File

@@ -149,15 +149,6 @@ class OCSAuthAPIController extends OCSController{
throw new OCSForbiddenException();
}

// we ask for the shared secret so we no longer have to ask the other server
// to request the shared secret
$this->jobList->remove('OCA\Federation\BackgroundJob\RequestSharedSecret',
[
'url' => $url,
'token' => $localToken
]
);

$this->jobList->add(
'OCA\Federation\BackgroundJob\GetSharedSecret',
[

+ 0
- 2
apps/federation/tests/Controller/OCSAuthAPIControllerTest.php View File

@@ -114,8 +114,6 @@ class OCSAuthAPIControllerTest extends TestCase {
if ($ok) {
$this->jobList->expects($this->once())->method('add')
->with('OCA\Federation\BackgroundJob\GetSharedSecret', ['url' => $url, 'token' => $token, 'created' => $this->currentTime]);
$this->jobList->expects($this->once())->method('remove')
->with('OCA\Federation\BackgroundJob\RequestSharedSecret', ['url' => $url, 'token' => $localToken]);
} else {
$this->jobList->expects($this->never())->method('add');
$this->jobList->expects($this->never())->method('remove');

Loading…
Cancel
Save