DiscoverView searches almost done. #38

Merged
anomalist merged 4 commits from discover-view-etc into master 2023-07-11 05:36:19 +00:00
2 changed files with 4 additions and 20 deletions
Showing only changes of commit 3f13d3ea33 - Show all commits
+2 -10
View File
@@ -166,11 +166,7 @@ export default class ContactsView extends Vue {
encodeURIComponent(identity.did) +
"&recipientDid=" +
encodeURIComponent(contact.did);
const token = await accessToken(identity);
const headers = {
"Content-Type": "application/json",
Authorization: "Bearer " + token,
};
const headers = this.getHeaders(identity);
const resp = await this.axios.get(url, { headers });
if (resp.status === 200) {
result = resp.data.data;
@@ -191,11 +187,7 @@ export default class ContactsView extends Vue {
encodeURIComponent(contact.did) +
"&recipientDid=" +
encodeURIComponent(identity.did);
const token2 = await accessToken(identity);
const headers2 = {
"Content-Type": "application/json",
Authorization: "Bearer " + token2,
};
const headers2 = await this.getHeaders(identity);
const resp2 = await this.axios.get(url2, { headers: headers2 });
if (resp2.status === 200) {
result = R.concat(result, resp2.data.data);
+2 -10
View File
@@ -457,11 +457,7 @@ export default class ContactsView extends Vue {
// Make the xhr request payload
const payload = JSON.stringify({ jwtEncoded: vcJwt });
const url = this.apiServer + "/api/v2/claim";
const token = await accessToken(identity);
const headers = {
"Content-Type": "application/json",
Authorization: "Bearer " + token,
};
const headers = await this.getHeaders(identity);
try {
const resp = await this.axios.post(url, payload, { headers });
@@ -683,11 +679,7 @@ export default class ContactsView extends Vue {
const payload = JSON.stringify({ jwtEncoded: vcJwt });
const url = this.apiServer + "/api/v2/claim";
const token = await accessToken(identity);
const headers = {
"Content-Type": "application/json",
Authorization: "Bearer " + token,
};
const headers = await this.getHeaders(identity);
try {
const resp = await this.axios.post(url, payload, { headers });