# Prevent email addresses from being counted as mentions

**URL:** https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763
**Category:** Bug
**Created:** [January 11, 2016, 6:30pm UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763 "2016-01-11T18:30:30Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![damien](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/damien/32/122035_2.png) [@damien](https://meta.discourse.org/u/damien)
#### Post date: [January 11, 2016, 6:30pm UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/1 "2016-01-11T18:30:30Z")

</div>

Hi there,

Is there any built-in way to prevent this behaviour or is a plugin ?

Thanks!

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [January 11, 2016, 6:33pm UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/2 "2016-01-11T18:33:04Z")

</div>

Not sure I understand what you mean since emails aren’t counted as mention (test: foo@damien.bar).

---

<div class="post-metadata">

### Author: ![gerhard](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gerhard/32/119479_2.png) [@gerhard](https://meta.discourse.org/u/gerhard)
#### Post date: [January 11, 2016, 7:29pm UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/3 "2016-01-11T19:29:38Z")

</div>

I think he means that email addresses are counted against the `max_mentions_per_post`.  
I can’t test it right now, but I think I noticed this too some time ago. Not sure if it still happens…

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [January 11, 2016, 11:18pm UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/4 "2016-01-11T23:18:08Z")

</div>

Aha if we can repro that we should fix @techapj.

---

<div class="post-metadata">

### Author: ![watchmanmonitor](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/watchmanmonitor/32/430970_2.png) [@watchmanmonitor](https://meta.discourse.org/u/watchmanmonitor)
#### Post date: [January 12, 2016, 1:55am UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/6 "2016-01-12T01:55:28Z")

</div>

Seems to be fixed.. I could do that as a new user on try .. [http://try.discourse.org/t/this-is-alot-of-emails/356](http://try.discourse.org/t/this-is-alot-of-emails/356)

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [January 12, 2016, 1:56am UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/7 "2016-01-12T01:56:48Z")

</div>

Yeah this is bust … tagging as a bug

[1@test.com](mailto:1@test.com) [1@best.com](mailto:1@best.com) @best @not

```plaintext
Post.find(162234).raw_mentions
=> ["test", "best", "not"]

```

There should be 0 raw mentions on my post here cause nobody was mentioned.

---

<div class="post-metadata">

### Author: ![damien](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/damien/32/122035_2.png) [@damien](https://meta.discourse.org/u/damien)
#### Post date: [January 12, 2016, 8:45am UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/8 "2016-01-12T08:45:02Z")

</div>

Exactly, sorry I could not provide more input.

I could not see any post or issue related to this problem, and I thought that may be related to some misusage of the application in some way eheh

Thanks for the quick answer!

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [January 12, 2016, 8:53am UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/9 "2016-01-12T08:53:48Z")

</div>

This is now fixed 🍕

[https://github.com/discourse/discourse/commit/96aa5b865ffc50e7ba25f343c0cfeed967552353](https://github.com/discourse/discourse/commit/96aa5b865ffc50e7ba25f343c0cfeed967552353)

Thanks @damien for reporting that issue 🙂

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [January 12, 2016, 8:53am UTC](https://meta.discourse.org/t/prevent-email-addresses-from-being-counted-as-mentions/37763/10 "2016-01-12T08:53:50Z")

</div>


