Skip to content
Snippets Groups Projects

Issue #3186587: Using User Tokens

2 unresolved threads

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
37 44 */
38 45 protected function init() {
39 46 if (!isset($this->client)) {
40 $this->client = Client::create($this->config->get('url'))
41 ->authenticate($this->config->get('token'), Client::AUTH_URL_TOKEN);
47 $localArgs = isset($this->authArguments) ? $this->authArguments : [$this->config->get('token'), Client::AUTH_URL_TOKEN];
  • Jürgen Haas
  • 23 23 */
    24 24 protected $client;
    25 25
    26 /**
    27 * @var array
    28 */
    29 protected $authArguments;
    30
    26 31 /**
    27 32 * Api constructor.
    28 33 *
    29 34 * @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
    35 * @param array|null $authArguments
    30 36 */
    31 public function __construct(ConfigFactoryInterface $config_factory) {
    37 public function __construct(ConfigFactoryInterface $config_factory, array $authArguments = NULL) {
  • David Brown added 1 commit

    added 1 commit

    • 97826a37 - Move the token arguments to init

    Compare with previous version

  • David Brown added 1 commit

    added 1 commit

    • 7164fed9 - Use double ?? instead of single ?

    Compare with previous version

  • Please register or sign in to reply
    Loading