diff --git a/CommunityToolkit.Authentication.Msal/CommunityToolkit.Authentication.Msal.csproj b/CommunityToolkit.Authentication.Msal/CommunityToolkit.Authentication.Msal.csproj
index 78acb3f..050e3e8 100644
--- a/CommunityToolkit.Authentication.Msal/CommunityToolkit.Authentication.Msal.csproj
+++ b/CommunityToolkit.Authentication.Msal/CommunityToolkit.Authentication.Msal.csproj
@@ -1,4 +1,5 @@
+
netstandard2.0
diff --git a/CommunityToolkit.Graph.Uwp/CommunityToolkit.Graph.Uwp.csproj b/CommunityToolkit.Graph.Uwp/CommunityToolkit.Graph.Uwp.csproj
index 931ba3c..f7a121f 100644
--- a/CommunityToolkit.Graph.Uwp/CommunityToolkit.Graph.Uwp.csproj
+++ b/CommunityToolkit.Graph.Uwp/CommunityToolkit.Graph.Uwp.csproj
@@ -21,17 +21,17 @@
UWP Community Toolkit Windows Controls Microsoft Graph Login Person PeoplePicker Presenter9.0
-
-
-
-
-
-
+
+
+
+
+
+
@@ -50,4 +50,5 @@
+
diff --git a/CommunityToolkit.Graph.Uwp/Controls/GraphPresenter/GraphPresenter.cs b/CommunityToolkit.Graph.Uwp/Controls/GraphPresenter/GraphPresenter.cs
index ed8edb7..abc710b 100644
--- a/CommunityToolkit.Graph.Uwp/Controls/GraphPresenter/GraphPresenter.cs
+++ b/CommunityToolkit.Graph.Uwp/Controls/GraphPresenter/GraphPresenter.cs
@@ -5,10 +5,10 @@
using System;
using System.Collections.Generic;
using System.Linq;
+using System.Text.Json;
using System.Threading;
using Microsoft.Graph;
using Microsoft.Toolkit.Uwp;
-using Newtonsoft.Json.Linq;
using Windows.System;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
@@ -20,14 +20,6 @@ namespace CommunityToolkit.Graph.Uwp.Controls
///
public class GraphPresenter : ContentPresenter
{
- ///
- /// Gets or sets a to be used to make a request to the graph. The results will be automatically populated to the property. Use a to change the presentation of the data.
- ///
- public IBaseRequestBuilder RequestBuilder
- {
- get { return (IBaseRequestBuilder)GetValue(RequestBuilderProperty); }
- set { SetValue(RequestBuilderProperty, value); }
- }
///
/// Identifies the dependency property.
@@ -38,6 +30,23 @@ public IBaseRequestBuilder RequestBuilder
public static readonly DependencyProperty RequestBuilderProperty =
DependencyProperty.Register(nameof(RequestBuilder), typeof(IBaseRequestBuilder), typeof(GraphPresenter), new PropertyMetadata(null));
+ ///
+ /// Initializes a new instance of the class.
+ ///
+ public GraphPresenter()
+ {
+ this.Loaded += this.GraphPresenter_Loaded;
+ }
+
+ ///
+ /// Gets or sets a to be used to make a request to the graph. The results will be automatically populated to the property. Use a to change the presentation of the data.
+ ///
+ public IBaseRequestBuilder RequestBuilder
+ {
+ get { return (IBaseRequestBuilder)this.GetValue(RequestBuilderProperty); }
+ set { this.SetValue(RequestBuilderProperty, value); }
+ }
+
///
/// Gets or sets the of item returned by the .
/// Set to the base item type and use the property to indicate if a collection is expected back.
@@ -59,52 +68,47 @@ public IBaseRequestBuilder RequestBuilder
///
public string OrderBy { get; set; }
- ///
- /// Initializes a new instance of the class.
- ///
- public GraphPresenter()
- {
- Loaded += GraphPresenter_Loaded;
- }
-
private async void GraphPresenter_Loaded(object sender, RoutedEventArgs e)
{
var dispatcherQueue = DispatcherQueue.GetForCurrentThread();
// Note: some interfaces from the Graph SDK don't implement IBaseRequestBuilder properly, see https://github.com/microsoftgraph/msgraph-sdk-dotnet/issues/722
- if (RequestBuilder != null)
+ if (this.RequestBuilder != null)
{
- var request = new BaseRequest(RequestBuilder.RequestUrl, RequestBuilder.Client) // TODO: Do we need separate Options here?
+ var request = new BaseRequest(this.RequestBuilder.RequestUrl, this.RequestBuilder.Client) // TODO: Do we need separate Options here?
{
Method = HttpMethods.GET,
- QueryOptions = QueryOptions?.Select(option => (Microsoft.Graph.QueryOption)option)?.ToList() ?? new List(),
+ QueryOptions = this.QueryOptions?.Select(option => (Microsoft.Graph.QueryOption)option)?.ToList() ?? new List(),
};
// Handle Special QueryOptions
- if (!string.IsNullOrWhiteSpace(OrderBy))
+ if (!string.IsNullOrWhiteSpace(this.OrderBy))
{
- request.QueryOptions.Add(new Microsoft.Graph.QueryOption("$orderby", OrderBy));
+ request.QueryOptions.Add(new Microsoft.Graph.QueryOption("$orderby", this.OrderBy));
}
try
{
- var response = await request.SendAsync