Improve capability of the AzureProvider::isUsable method

Created on 14 May 2025, about 6 hours ago

Problem/Motivation

The current code for AzureProvider::isUsable() doesn't factor in the $operation_type argument, and thus always returns FALSE when it isn't provided.

  public function isUsable(?string $operation_type = NULL, array $capabilities = []): bool {
    if (in_array($operation_type, $this->getSupportedOperationTypes())) {
      return TRUE;
    }
    return FALSE;
  }

Steps to reproduce

Configure an Azure model/provider and then visit the Admin -> Reports -> Status page and note that the AI module reports no configured providers.

Proposed resolution

Add additional logic to the method.

πŸ“Œ Task
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States jhedstrom Portland, OR

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024