From 3b583593fbfa3d144c708ed30c4ce5778d7d0ac7 Mon Sep 17 00:00:00 2001 From: Niladri Dutta Date: Wed, 31 Oct 2018 09:38:24 +0530 Subject: [PATCH] use "SetClickTracking" method to disable clicktracking (#9325) use `SetClickTracking` method instead of directly accessing the public property `TrackingSettings`. Reference #9235 Related to #6268 --- .../sample/WebPWrecover21/Services/EmailSender.cs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/aspnetcore/security/authentication/accconfirm/sample/WebPWrecover21/Services/EmailSender.cs b/aspnetcore/security/authentication/accconfirm/sample/WebPWrecover21/Services/EmailSender.cs index 838ede6e49..76df1edb55 100644 --- a/aspnetcore/security/authentication/accconfirm/sample/WebPWrecover21/Services/EmailSender.cs +++ b/aspnetcore/security/authentication/accconfirm/sample/WebPWrecover21/Services/EmailSender.cs @@ -34,12 +34,9 @@ namespace WebPWrecover.Services // Disable click tracking. // See https://sendgrid.com/docs/User_Guide/Settings/tracking.html - msg.TrackingSettings = new TrackingSettings - { - ClickTracking = new ClickTracking { Enable = false } - }; + msg.SetClickTracking(false, false); return client.SendEmailAsync(msg); } } -} \ No newline at end of file +}