# How do disable private messages between non staff users?

**URL:** https://meta.discourse.org/t/how-do-disable-private-messages-between-non-staff-users/31436
**Category:** Support
**Created:** [7월 26, 2015, 2:25오전 UTC](https://meta.discourse.org/t/how-do-disable-private-messages-between-non-staff-users/31436 "2015-07-26T02:25:12Z")
**Posts on this page:** 1
**Showing post:** 10

<div class="post-metadata">

### Author: ![Mittineague](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mittineague/32/114259_2.png) [@Mittineague](https://meta.discourse.org/u/Mittineague)
#### Post date: [7월 27, 2015, 3:34오전 UTC](https://meta.discourse.org/t/how-do-disable-private-messages-between-non-staff-users/31436/10 "2015-07-27T03:34:08Z")

</div>

> [@codinghorror](#):
>
> Staff are always immune from these kinds of restrictions.

Hmmmm, I’m missing seeing that in the guardian.rb file.

```plaintext
  def can_send_private_message?(target)
    (target.is_a?(Group) || target.is_a?(User)) &&
    # User is authenticated
    authenticated? &&
    # Can't send message to yourself
    is_not_me?(target) &&
    # Have to be a basic level at least
    @user.has_trust_level?(TrustLevel[1]) &&
    # PMs are enabled
    (SiteSetting.enable_private_messages ||
      @user.username == SiteSetting.site_contact_username ||
      @user == Discourse.system_user) &&
    # Can't send PMs to suspended users
    (is_staff? || target.is_a?(Group) || !target.suspended?)
  end

```

---

_[View the full topic](https://meta.discourse.org/t/how-do-disable-private-messages-between-non-staff-users/31436)._
