Ejemplo n.º 1
0
            static async private Task <MatrixRequestResult> PutAsync(string uri, JObject body)
            {
                var obj = await json_req.PutAsync(new Uri(uri), body);

                var result = new MatrixRequestResult(obj);

                switch (result.status)
                {
                case "UNKNOWN_ERROR":
                    throw new MatrixException.ServerError();

                case "NOT_AUTHORIZED":
                    throw new MatrixException.NotLogin();

                default:
                    break;
                }
                return(result);
            }