Skip to content

Commit

Permalink
Fetch request will now include cookies
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonyjb committed Jul 22, 2018
1 parent 04aac74 commit ec7f937
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion module/typeahead.js
Original file line number Diff line number Diff line change
Expand Up @@ -731,7 +731,10 @@ Typeahead.behaviours = {
url = `${url}&q=${qs}`
}

return fetch(url)
return fetch(
url,
{'credentials': 'include'}
)
.then((response) => {
return response.json()
})
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "manhattan-typeahead",
"version": "1.0.9",
"version": "1.0.10",
"description": "Type-a-head and tokens for form fields.",
"engines": {
"node": ">=8.9.4"
Expand Down

0 comments on commit ec7f937

Please sign in to comment.