Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions lib/private/Authentication/LoginCredentials/Store.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<?php
<?php declare(strict_types=1);

/**
* @copyright 2016 Christoph Wurst <[email protected]>
*
Expand Down Expand Up @@ -82,8 +83,8 @@ public function setSession(ISession $session) {
* @return ICredentials the login credentials of the current user
* @throws CredentialsUnavailableException
*/
public function getLoginCredentials() {
if (is_null($this->tokenProvider)) {
public function getLoginCredentials(): ICredentials {
if ($this->tokenProvider === null) {
throw new CredentialsUnavailableException();
}

Expand Down
9 changes: 5 additions & 4 deletions lib/public/Authentication/LoginCredentials/IStore.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<?php
<?php declare(strict_types=1);

/**
* @copyright 2016 Christoph Wurst <[email protected]>
*
Expand Down Expand Up @@ -29,7 +30,7 @@
* @since 12
*/
interface IStore {

/**
* Get login credentials of the currently logged in user
*
Expand All @@ -38,6 +39,6 @@ interface IStore {
* @throws CredentialsUnavailableException
* @return ICredentials the login credentials of the current user
*/
public function getLoginCredentials();
public function getLoginCredentials(): ICredentials;

}