# Can you update the init function of the new module to be executed if i upgrade by adding a new module to the previously distributed package?

**URL:** <https://forums.sui.io/t/can-you-update-the-init-function-of-the-new-module-to-be-executed-if-i-upgrade-by-adding-a-new-module-to-the-previously-distributed-package/48835>\
**Category:** Sui Network\
**Tags:** sui, testnet\
**Created:** [July 9, 2025, 5:28am UTC](https://forums.sui.io/t/can-you-update-the-init-function-of-the-new-module-to-be-executed-if-i-upgrade-by-adding-a-new-module-to-the-previously-distributed-package/48835 "2025-07-09T05:28:13Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![casehun\_07784](https://dub1.discourse-cdn.com/sui/user_avatar/forums.sui.io/casehun_07784/32/31353_2.png) [@casehun\_07784](https://forums.sui.io/u/casehun_07784)\
**Post date:** [July 9, 2025, 5:28am UTC](https://forums.sui.io/t/can-you-update-the-init-function-of-the-new-module-to-be-executed-if-i-upgrade-by-adding-a-new-module-to-the-previously-distributed-package/48835/1 "2025-07-09T05:28:13Z")

</div>

If i upgrade by adding a new module to a previously distributed package, the init function of the new module will not be executed, which is the hassle of having to call it separately.

Is there any particular reason why the init function of the new module should not be called when upgrading

---

<div class="post-metadata">

**Author:** ![Kungfupanda](https://avatars.discourse-cdn.com/v4/letter/k/a587f6/32.png) [@Kungfupanda](https://forums.sui.io/u/Kungfupanda)\
**Post date:** [July 9, 2025, 11:36am UTC](https://forums.sui.io/t/can-you-update-the-init-function-of-the-new-module-to-be-executed-if-i-upgrade-by-adding-a-new-module-to-the-previously-distributed-package/48835/2 "2025-07-09T11:36:12Z")

</div>

This is a very good compain
