diff --git a/src/Directory.Build.props b/src/Directory.Build.props
index e3e1feb526..a57bbf9638 100644
--- a/src/Directory.Build.props
+++ b/src/Directory.Build.props
@@ -60,4 +60,10 @@
+
+
+
+
+
+
diff --git a/src/Sentry.Analyzers/Sentry.Analyzers.csproj b/src/Sentry.Analyzers/Sentry.Analyzers.csproj
index 223a1434f8..e855f9d246 100644
--- a/src/Sentry.Analyzers/Sentry.Analyzers.csproj
+++ b/src/Sentry.Analyzers/Sentry.Analyzers.csproj
@@ -24,8 +24,18 @@
https://github.com/SimonCropp/Polyfill
-->
-
+
+
+
+ true
+
+
+
+
+ $([System.String]::Copy('$(DefineConstants)').Replace('FeatureMemory','').Replace(';;',';'))
+
+
diff --git a/src/Sentry/Internal/Extensions/CollectionsExtensions.cs b/src/Sentry/Internal/Extensions/CollectionsExtensions.cs
index 8d7b6f7bdf..79a0fb4d44 100644
--- a/src/Sentry/Internal/Extensions/CollectionsExtensions.cs
+++ b/src/Sentry/Internal/Extensions/CollectionsExtensions.cs
@@ -69,18 +69,14 @@ public static IEnumerable> WhereNotNullValue> Append(
this IEnumerable> source, TKey key, TValue value) =>
source.Append(new KeyValuePair(key, value));
+
public static IReadOnlyList AsReadOnly(this IList list) =>
list as IReadOnlyList ?? new ReadOnlyCollection(list);
-#if !NET7_0_OR_GREATER
- public static IReadOnlyDictionary AsReadOnly(this IDictionary dictionary)
- where TKey : notnull =>
- new ReadOnlyDictionary(dictionary);
-#endif
-
public static IEnumerable ExceptNulls(this IEnumerable source) =>
source.Where(x => x != null).Select(x => x!);
diff --git a/src/Sentry/Sentry.csproj b/src/Sentry/Sentry.csproj
index a2b75db0ae..f2f88ca2d5 100644
--- a/src/Sentry/Sentry.csproj
+++ b/src/Sentry/Sentry.csproj
@@ -65,8 +65,12 @@
https://github.com/SimonCropp/Polyfill
-->
-
+
+
+ $(DefineConstants);FeatureHttp
+ $(DefineConstants);FeatureHttp
+
+
+
+
+
+