Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Latest downloadable nuget 1.0.24 does not match github #120

Open
siggipop opened this issue Mar 23, 2024 · 0 comments
Open

Latest downloadable nuget 1.0.24 does not match github #120

siggipop opened this issue Mar 23, 2024 · 0 comments

Comments

@siggipop
Copy link

I notice the nuget packaged contained some code that looked unfinished or different from github branch

From github master branch the Get method start like so:

public async Task<ResultType> Get<ResultType>(string entityCollection, string key, CRMGetListOptions QueryOptions = null)
{
    await CheckAuthToken();

    string fullUrl = string.Empty;
    if (key.Equals(Guid.Empty.ToString()) || String.IsNullOrEmpty(key))
        fullUrl = BuildGetUrl(entityCollection, QueryOptions);
    else
        fullUrl = BuildGetUrl(entityCollection + "(" + key + ")", QueryOptions);
    HttpRequestMessage request = new HttpRequestMessage(new HttpMethod("GET"), fullUrl);

But in the Nuget packet 1.0.24, the method starts like so:

public async Task<ResultType> Get<ResultType>(string entityCollection, string key, CRMGetListOptions QueryOptions = null)
{
   await CheckAuthToken();
   _ = string.Empty;
   HttpRequestMessage request = new HttpRequestMessage(requestUri: (!key.Equals(Guid.Empty.ToString()) && !string.IsNullOrEmpty(key)) ? BuildGetUrl(entityCollection + "(" + key + ")", QueryOptions) : BuildGetUrl(entityCollection, QueryOptions), method: new HttpMethod("GET"));
   if (QueryOptions?.FormattedValues ?? false)
   {
       request.Headers.Add("Prefer", "odata.include-annotations=\"OData.Community.Display.V1.FormattedValue\"");
   }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant