Avoid warnings due to duplicate loading of auth files, fixes #4971
parent
9d95456bb0
commit
6d1e8ebf90
|
@ -65,6 +65,11 @@ abstract class BaseIO implements IOInterface
|
||||||
protected function checkAndSetAuthentication($repositoryName, $username, $password = null)
|
protected function checkAndSetAuthentication($repositoryName, $username, $password = null)
|
||||||
{
|
{
|
||||||
if ($this->hasAuthentication($repositoryName)) {
|
if ($this->hasAuthentication($repositoryName)) {
|
||||||
|
$auth = $this->getAuthentication($repositoryName);
|
||||||
|
if ($auth['username'] === $username && $auth['password'] === $password) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
$this->writeError(
|
$this->writeError(
|
||||||
sprintf(
|
sprintf(
|
||||||
"<warning>Warning: You should avoid overwriting already defined auth settings for %s.</warning>",
|
"<warning>Warning: You should avoid overwriting already defined auth settings for %s.</warning>",
|
||||||
|
|
Loading…
Reference in New Issue