Skip to content

AppSettings has wrong type (<string, IAppSetting> should be <string, string>) #46

Description

@MattMcL4475

Currently when retrieving the AppSettings from a WebApp, the object that is returned is:

IReadOnlyDictionary<string, IAppSetting> AppSettings

This seems to be incorrect; I would expect AppSettings to contain a dictionary of key/value pairs. Instead, it contains a dictionary of key/[value.key, value.value] pairs.

Notice how one has to access the desired key/value pair:

var webApp = azure.WebApps.GetById(resourceId);
var settings = webApp.AppSettings;
foreach (var setting in settings)
{
    var key = setting.Value.Key;  // this is strange.  Should be "setting.Key"
    var value = setting.Value.Value; // this is strange.  Should be "setting.Value"
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions