Fixed compatibility issue with PHP 5.3 for OAuthUserProvider class

This commit is contained in:
Frederic Guillot 2016-07-10 22:05:45 -04:00
parent b56295fa7b
commit 3813acf199
No known key found for this signature in database
GPG Key ID: 92D77191BA7FBC99
2 changed files with 7 additions and 11 deletions

View File

@ -10,6 +10,10 @@ Improvements:
* Display TOTP issuer for 2FA
Bug fixes:
* Fixed compatibility issue with PHP 5.3 for OAuthUserProvider class
Version 1.0.31
--------------

View File

@ -12,14 +12,6 @@ use Kanboard\Core\User\UserProviderInterface;
*/
abstract class OAuthUserProvider implements UserProviderInterface
{
/**
* Get external id column name
*
* @access public
* @return string
*/
abstract public function getExternalIdColumn();
/**
* User properties
*
@ -69,7 +61,7 @@ abstract class OAuthUserProvider implements UserProviderInterface
*/
public function getExternalId()
{
return $this->user['id'];
return isset($this->user['id']) ? $this->user['id'] : '';
}
/**
@ -102,7 +94,7 @@ abstract class OAuthUserProvider implements UserProviderInterface
*/
public function getName()
{
return $this->user['name'];
return isset($this->user['name']) ? $this->user['name'] : '';
}
/**
@ -113,7 +105,7 @@ abstract class OAuthUserProvider implements UserProviderInterface
*/
public function getEmail()
{
return $this->user['email'];
return isset($this->user['email']) ? $this->user['email'] : '';
}
/**