# Internal error: undefined method \`visibility\_reason\_id'

**URL:** <https://meta.discourse.org/t/internal-error-undefined-method-visibility-reason-id/308317>\
**Category:** Self-hosting\
**Created:** [May 16, 2024, 8:55pm UTC](https://meta.discourse.org/t/internal-error-undefined-method-visibility-reason-id/308317 "2024-05-16T20:55:10Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![jeanas](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jeanas/32/281211_2.png) [@jeanas](https://meta.discourse.org/u/jeanas)\
**Post date:** [May 16, 2024, 9:13pm UTC](https://meta.discourse.org/t/internal-error-undefined-method-visibility-reason-id/308317/2 "2024-05-16T21:13:50Z")

</div>

Looking at the code, it seems that `visibility_reason_id` and such are database fields new in this version, that were supposed to be added to the existing database by migrations scripts (e.g., `db/migrate/20240423013808_add_visibility_reason_id_to_topics.rb`). I suspect that the upgrade stopped halfway before running these.

Is there a way to cleanly roll back to 3.3.0beta1 and redo the migration? If I do `git checkout v3.3.0.beta1` inside the Docker container (`./launcher enter app`), is it dangerous?

---

_[View the full topic](https://meta.discourse.org/t/internal-error-undefined-method-visibility-reason-id/308317)._
