public FeaturesManager GetFeaturesManager(HttpContext httpContext)
        {
            string flightsOverride = (httpContext == null) ? null : RequestDispatcherUtilities.GetStringUrlParameter(httpContext, "flights");
            HttpCookieCollection httpCookieCollection = (httpContext == null) ? null : httpContext.Request.Cookies;
            HttpCookie           httpCookie           = (httpCookieCollection == null) ? null : httpCookieCollection.Get("flights");

            if (httpCookie != null && !string.IsNullOrEmpty(httpCookie.Value) && httpCookie.Value.Equals("none", StringComparison.InvariantCultureIgnoreCase))
            {
                flightsOverride = "none";
            }
            return(this.GetFeaturesManagerInternal(flightsOverride));
        }
 public bool IsFeatureEnabled(string featureId)
 {
     if (!string.IsNullOrEmpty(featureId) && featureId == this.snapshot.OwaClientServer.ModernGroups.Name)
     {
         if (RequestDispatcherUtilities.GetStringUrlParameter(HttpContext.Current, "sharepointapp") == "true")
         {
             return(false);
         }
         if (this.recipientTypeDetails == RecipientTypeDetails.SharedMailbox)
         {
             return(false);
         }
     }
     return(string.IsNullOrEmpty(featureId) || (!(featureId == this.snapshot.OwaClientServer.O365ParityHeader.Name) && !(featureId == this.snapshot.OwaClientServer.O365Header.Name) && !(featureId == this.snapshot.OwaClientServer.O365G2Header.Name)) || !(RequestDispatcherUtilities.GetStringUrlParameter(HttpContext.Current, "sharepointapp") == "true"));
 }