Example #1
0
        protected async override Task <object> OnPerform()
        {
            var response = await _fuelPumpRestClient.LoadTierLevel();

            var data = await response.Content.ReadAsStringAsync();

            switch (response.StatusCode)
            {
            case HttpStatusCode.OK:
                var contract = new DeSerializer().MapTierLevel(data);
                return(new Mapper().MapTierLevel(contract));

            default:
                return(await HandleExceptions(response));
            }
        }