using System.Linq; using System.Reflection; #nullable enable internal static class SampleHelper { public static string? GetReleasesDir() => Assembly.GetEntryAssembly()? .GetCustomAttributes() .Where(x => x.Key == "VelopackSampleReleaseDir") .Single().Value; } #nullable restore