src/Stratis.FederatedSidechains.AdminDashboard/Controllers/HomeController.cs
/// <summary>
/// Check if the federation is enabled, it's only called from the SignalR event
/// </summary>
/// <returns>True or False</returns>
Check if the federation is enabled, it's only called from the SignalR event
Check if the federation is enabled it ' s only called from the SignalR event
[Ajax]
        [Route("check-federation")]
        public async Task<IActionResult> CheckFederationAsync()
        {
            ApiResponse getMainchainFederationInfo = await ApiRequester.GetRequestAsync(this.defaultEndpointsSettings.StratisNode, "/api/FederationGateway/info");
            if(getMainchainFederationInfo.IsSuccess)
            {
                return Json(getMainchainFederationInfo.Content.active);
            }
            return Json(true);
        }
[ Ajax ] [ Route ( " " ) ] public async Task < IActionResult > CheckFederationAsync ( ) { ApiResponse getMainchainFederationInfo = await ApiRequester . GetRequestAsync ( this . defaultEndpointsSettings . StratisNode , " " ) ; if ( getMainchainFederationInfo . IsSuccess ) { return Json ( getMainchainFederationInfo . Content . active ) ; } return Json ( true ) ; }
Check if the federation is enabled, it's only called from the SignalR event
Check if the federation is enabled it ' s only called from the SignalR event
True or False
True or False