# "Save Invite" button not working "is not a function" error \[cache issue\]

**URL:** <https://meta.discourse.org/t/save-invite-button-not-working-is-not-a-function-error-cache-issue/294660>\
**Category:** Product Support\
**Tags:** invites\
**Created:** [February 8, 2024, 9:21am UTC](https://meta.discourse.org/t/save-invite-button-not-working-is-not-a-function-error-cache-issue/294660 "2024-02-08T09:21:15Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![gassim](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gassim/32/220910_2.png) [@gassim](https://meta.discourse.org/u/gassim)\
**Post date:** [February 8, 2024, 9:21am UTC](https://meta.discourse.org/t/save-invite-button-not-working-is-not-a-function-error-cache-issue/294660/1 "2024-02-08T09:21:15Z")

</div>

Hi

When I click on the ‘save invite’ after filling in the information for the invitation, nothing happens, and in the console (DevTools) it shows an error “this.invite.save is not a function.” I believe this is a bug, could you please confirm that it will be fixed?

see screenshot:

 ![image](https://global.discourse-cdn.com/meta/original/4X/7/b/b/7bbfea5282021a1d3f498f898ace7a378550d61c.jpeg)

For anyone facing the same issue, you can temporarily create invitation links using the Discourse API:

```plaintext
var myHeaders = new Headers();
myHeaders.append("Api-Username", "Gassim");
myHeaders.append("Content-Type", "application/json");
myHeaders.append("api-key", "amazingseceretAPIkey");

var raw = JSON.stringify({
  "max_redemptions_allowed": 1000000,
  "topic_id": 56955,
  "group_names": "AMAZINGGROUP",
  "expires_at": "2024-02-08T12:00:00.000Z"
});

var requestOptions = {
  method: 'POST',
  headers: myHeaders,
  body: raw,
  redirect: 'follow'
};

fetch("domain/invites.json", requestOptions)
  .then(response => response.text())
  .then(result => console.log(result))
  .catch(error => console.log('error', error));

```

Thanks!

---

_[View the full topic](https://meta.discourse.org/t/save-invite-button-not-working-is-not-a-function-error-cache-issue/294660)._
