private bool ExtractStateObject(HTTPSourcedCommand c, out UserState cs) { try { JObject jo = c.Data as JObject; cs = UserState.InstantiateUserState(jo); return(true); } catch (Exception ex) { cs = null; Logger.Error($"During '{c.CommandType}' system was unable to handle user's information. Exception:{ex.ToString()}"); HTTPExternalInterface.HandleFailedStateMessage(new HTTPDestinedCommandStateEvent(MicroServices.ProcessingStatus.Failed, $"During '{c.CommandType}' system was unable to handle user's information.", c), true); } return(false); }