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
12 changes: 6 additions & 6 deletions lib/Db/Id4Me.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@
use OCP\AppFramework\Db\Entity;

/**
* @method string getIdentifier()
* @method void setIdentifier(string $identifier)
* @method string getClientId()
* @method void setClientId(string $clientId)
* @method string getClientSecret()
* @method void setClientSecret(string $clientSecret)
* @method \string getIdentifier()
* @method \void setIdentifier(string $identifier)
* @method \string getClientId()
* @method \void setClientId(string $clientId)
* @method \string getClientSecret()
* @method \void setClientSecret(string $clientSecret)
*/
class Id4Me extends Entity {

Expand Down
21 changes: 11 additions & 10 deletions lib/Db/Session.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
namespace OCA\UserOIDC\Db;

use OCP\AppFramework\Db\Entity;
use OCP\DB\Types;

/**
* @method \string getSid()
Expand Down Expand Up @@ -56,16 +57,16 @@ class Session extends Entity implements \JsonSerializable {
protected $idpSessionClosed;

public function __construct() {
$this->addType('sid', 'string');
$this->addType('sub', 'string');
$this->addType('iss', 'string');
$this->addType('authtoken_id', 'integer');
$this->addType('nc_session_id', 'string');
$this->addType('created_at', 'integer');
$this->addType('id_token', 'string');
$this->addType('user_id', 'string');
$this->addType('provider_id', 'integer');
$this->addType('idp_session_closed', 'integer');
$this->addType('sid', Types::STRING);
$this->addType('sub', Types::STRING);
$this->addType('iss', Types::STRING);
$this->addType('authtokenId', Types::INTEGER);
$this->addType('ncSessionId', Types::STRING);
$this->addType('createdAt', Types::INTEGER);
$this->addType('idToken', Types::STRING);
$this->addType('userId', Types::STRING);
$this->addType('providerId', Types::INTEGER);
$this->addType('idpSessionClosed', Types::INTEGER);
}

#[\ReturnTypeWillChange]
Expand Down
11 changes: 6 additions & 5 deletions lib/Db/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,13 @@
namespace OCA\UserOIDC\Db;

use OCP\AppFramework\Db\Entity;
use OCP\DB\Types;

/**
* @method string getUserId()
* @method void setUserId(string $userId)
* @method string getDisplayName()
* @method void setDisplayName(string $displayName)
* @method \string getUserId()
* @method \void setUserId(string $userId)
* @method \string getDisplayName()
* @method \void setDisplayName(string $displayName)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These seem unnecessary

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's useful for Psalm in PhpStorm for some reason. Without this it thinks the return types are like \OCA\UserOIDC\Db\string.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mh, never happened to me

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

psalm up to date?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, Psalm up-to-date.

*/
class User extends Entity {

Expand All @@ -25,6 +26,6 @@ class User extends Entity {
protected $displayName;

public function __construct() {
$this->addType('user_id', 'string');
$this->addType('userId', Types::STRING);
}
}
Loading