Skip to content

Commit fb4e987

Browse files
Update GitHub.php
As basic authentication no longer can be set, basic authentication should be removed.
1 parent 5a44f04 commit fb4e987

File tree

1 file changed

+0
-21
lines changed
  • administrator/components/com_patchtester/PatchTester/GitHub

1 file changed

+0
-21
lines changed

administrator/components/com_patchtester/PatchTester/GitHub/GitHub.php

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -135,27 +135,6 @@ protected function fetchUrl($path, $page = 0, $limit = 0)
135135
// Get a new Uri object using the API URL and given path.
136136
$uri = new Uri($this->options->get('api.url') . $path);
137137

138-
// Only apply basic authentication if an access token is not set
139-
if ($this->options->get('gh.token', false) === false)
140-
{
141-
// Use basic authentication
142-
if ($this->options->get('api.username', false))
143-
{
144-
$username = $this->options->get('api.username');
145-
$username = str_replace('@', '%40', $username);
146-
$username = str_replace('#', '%23', $username);
147-
$uri->setUser($username);
148-
}
149-
150-
if ($this->options->get('api.password', false))
151-
{
152-
$password = $this->options->get('api.password');
153-
$password = str_replace('@', '%40', $password);
154-
$password = str_replace('#', '%23', $password);
155-
$uri->setPass($password);
156-
}
157-
}
158-
159138
// If we have a defined page number add it to the JUri object.
160139
if ($page > 0)
161140
{

0 commit comments

Comments
 (0)