diff options
author | brantje <brantje@gmail.com> | 2017-02-06 13:59:03 +0300 |
---|---|---|
committer | brantje <brantje@gmail.com> | 2017-02-06 14:17:37 +0300 |
commit | 9c35282f89b18536a851292e26909244cbf6c465 (patch) | |
tree | f6897e1b2a0dc2b804f3862f5cc170a7ba97b2eb /controller | |
parent | 7326967c2195189476c7a47df1482d964c8d4345 (diff) |
Small fixes for 2.0.1
Fix for going back from deleted credentials
Use method
Diffstat (limited to 'controller')
-rw-r--r-- | controller/credentialcontroller.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/controller/credentialcontroller.php b/controller/credentialcontroller.php index 7d47ecd4..1b116b64 100644 --- a/controller/credentialcontroller.php +++ b/controller/credentialcontroller.php @@ -292,7 +292,10 @@ class CredentialController extends ApiController { '', $this->userId, Activity::TYPE_ITEM_ACTION); $this->sharingService->unshareCredential($credential->getGuid()); foreach ($this->credentialRevisionService->getRevisions($credential->getId()) as $revision) { - $this->credentialRevisionService->deleteRevision($revision['id'], $this->userId); + $id = $revision->getId(); + if(isset($id)){ + $this->credentialRevisionService->deleteRevision($id, $this->userId); + } } } |