# How to auto remove from groups when trust level falls?

**URL:** <https://meta.discourse.org/t/how-to-auto-remove-from-groups-when-trust-level-falls/200231>\
**Category:** Product Support\
**Created:** [August 12, 2021, 6:06pm UTC](https://meta.discourse.org/t/how-to-auto-remove-from-groups-when-trust-level-falls/200231 "2021-08-12T18:06:53Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Post date:** [August 13, 2021, 1:30pm UTC](https://meta.discourse.org/t/how-to-auto-remove-from-groups-when-trust-level-falls/200231/6 "2021-08-13T13:30:26Z")

</div>

This might work in the rails console

```plaintext
./launcher enter app
rails c

```

Then, this:

```
User.where(manual_locked_trust_level: 3).update_all(manual_locked_trust_level: nil, trust_level: 1)

```

That will find all users locked to trust level 3, unlock their trust level and set their trust level to 1.

---

_[View the full topic](https://meta.discourse.org/t/how-to-auto-remove-from-groups-when-trust-level-falls/200231)._
