Antonio-Maranhao commented on a change in pull request #1065: Remove JQuery
uses from documents addon
URL: https://github.com/apache/couchdb-fauxton/pull/1065#discussion_r173823329
##########
File path: app/addons/documents/doc-editor/actions.js
##########
@@ -79,33 +80,24 @@ function hideDeleteDocModal () {
}
function deleteDoc (doc) {
- var databaseName = doc.database.safeID();
- var query = '?rev=' + doc.get('_rev');
-
- $.ajax({
- url: FauxtonAPI.urls('document', 'server', databaseName, doc.safeID(),
query),
- type: 'DELETE',
- headers: {
- 'Accept': 'application/json',
- 'Content-Type': 'application/json',
- },
- xhrFields: {
- withCredentials: true
Review comment:
The functions in `core/ajax` all use `credentials: 'include'`
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services