# New Candid Version and Catching Send Failures: Motoko Updates

**URL:** <https://forum.dfinity.org/t/new-candid-version-and-catching-send-failures-motoko-updates/18410>\
**Category:** Language Support\
**Tags:** Motoko\
**Created:** [February 7, 2023, 3:24pm UTC](https://forum.dfinity.org/t/new-candid-version-and-catching-send-failures-motoko-updates/18410 "2023-02-07T15:24:13Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![chenyan](https://avatars.discourse-cdn.com/v4/letter/c/35a633/32.png) [@chenyan](https://forum.dfinity.org/u/chenyan)\
**Post date:** [February 7, 2023, 6:25pm UTC](https://forum.dfinity.org/t/new-candid-version-and-catching-send-failures-motoko-updates/18410/3 "2023-02-07T18:25:23Z")

</div>

As an example, we have a function that returns `opt variant { Type1; Type2 }`. And we want to extend the variant tag to `opt variant { Type1; Type2; Type3 }`. This was not allowed in the old candid library, or we have to upgrade both the server and client code at the same time.

With the new Candid version, you can do this safely without updating the client code: When the client receives `Type1` or `Type2`, existing code already covers that; when the client receives `Type3`, the value becomes `null`, which will be handled by the `null` case. No client code update is necessary unless the client code needs to handle the new `Type3` variant.

---

_[View the full topic](https://forum.dfinity.org/t/new-candid-version-and-catching-send-failures-motoko-updates/18410)._
