/// <inheritdoc />
        public async Task <TextResource> GetTextResourceAsync(string lang, string name)
        {
            var response = await _service.GetTextResourceAsync(lang, name);

            switch (response)
            {
            case TextResource result:
                return(result);

            case ErrorResponse error:
                throw new Exception(error.ErrorMessage);
            }

            return(null);
        }