# {{CurrentUser}} template is being rendered as \[object Object\]

**URL:** <https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741>\
**Category:** Get Help\
**Created:** [January 23, 2024, 11:21pm UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741 "2024-01-23T23:21:08Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![interr0bangr](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/interr0bangr/32/8089_2.png) [@interr0bangr](https://community.fibery.io/u/interr0bangr)\
**Post date:** [January 23, 2024, 11:21pm UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741/1 "2024-01-23T23:21:08Z")

</div>

I have a button that will send an email when it’s clicked.

I’m trying to get the email signature of the person who clicked the button to be appended to the end of the email that gets sent.

When I try to use {{CurrentUser.Signature}} in the email markdown, it gets rendered as “[object Object]”, but when I use something like {{CurrentUser.Email}} it renders the field just fine.

My signature field is a rich-text field, whereas the email field is text. Is it something simple I’m missing or not understanding?

---

<div class="post-metadata">

**Author:** ![Matt\_Blais](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/matt_blais/32/1464_2.png) [@Matt\_Blais](https://community.fibery.io/u/Matt_Blais)\
**Post date:** [January 23, 2024, 11:24pm UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741/2 "2024-01-23T23:24:18Z")

</div>

Is “Signature” a field in the User DB?

---

<div class="post-metadata">

**Author:** ![interr0bangr](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/interr0bangr/32/8089_2.png) [@interr0bangr](https://community.fibery.io/u/interr0bangr)\
**Post date:** [January 23, 2024, 11:40pm UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741/3 "2024-01-23T23:40:28Z")

</div>

Yep!

 ![Cameron-Blakey-—-User-Fibery](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/d/db029a6aa87e91b1171eca889ff754387f4cd6d4.jpeg)

Here’s the settings I’m using for the button/email too:

 ![Gmail-Database-Fibery](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/4/4415fecdf3c9a041171091b5debdfc2c374cc858.jpeg)

---

<div class="post-metadata">

**Author:** ![Matt\_Blais](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/matt_blais/32/1464_2.png) [@Matt\_Blais](https://community.fibery.io/u/Matt_Blais)\
**Post date:** [January 23, 2024, 11:53pm UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741/4 "2024-01-23T23:53:07Z")

</div>

This is a bit awkward, but it works for me:

```auto
<%
const rtfield = 'Signature' // Name of User Rich-Text field
const fibery = context.getService('fibery')
const secret = args.currentUser[rtfield].Secret
const content = await fibery.getDocumentContent(secret, 'md')
%><%= content %>

```

---

<div class="post-metadata">

**Author:** ![YvetteLans](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/yvettelans/32/6101_2.png) [@YvetteLans](https://community.fibery.io/u/YvetteLans)\
**Post date:** [January 24, 2024, 10:34am UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741/5 "2024-01-24T10:34:42Z")

</div>

Does emailing via Fibery works well for you? We don’t use it yet but thinking about using it 😄

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [January 24, 2024, 10:56am UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741/6 "2024-01-24T10:56:57Z")

</div>

It is not possible using markdown to get the contents of rich text fields from related entities (only from rich text fields from the triggering entity) sorry.

---

<div class="post-metadata">

**Author:** ![njyo](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/njyo/32/923_2.png) [@njyo](https://community.fibery.io/u/njyo)\
**Post date:** [January 24, 2024, 12:23pm UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741/7 "2024-01-24T12:23:09Z")

</div>

Emails from Fibery work well for us. We’ve created a [support@company.co](mailto:support@company.co) account and send a good amount of automated and custom emails.

Of course, yes, would love more Markdown and traversal options. Always. 😉

---

<div class="post-metadata">

**Author:** ![interr0bangr](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/interr0bangr/32/8089_2.png) [@interr0bangr](https://community.fibery.io/u/interr0bangr)\
**Post date:** [January 24, 2024, 2:48pm UTC](https://community.fibery.io/t/currentuser-template-is-being-rendered-as-object-object/5741/8 "2024-01-24T14:48:49Z")

</div>

> [@Matt\_Blais](#):
>
> ```auto
> <%
> const rtfield = 'Signature' // Name of User Rich-Text field
> const fibery = context.getService('fibery')
> const secret = args.currentUser[rtfield].Secret
> const content = await fibery.getDocumentContent(secret, 'md')
> %><%= content %>
> 
> ```

This totally works, thanks so much!

I really need to start learning how to script things myself…
