From 80d7ec42324413a551840c6eff72d13ab70bc0e2 Mon Sep 17 00:00:00 2001 From: nscuro Date: Mon, 11 Mar 2024 14:38:45 +0100 Subject: [PATCH] Fix API key rows not being displayed The keyword `this` is not available when using `() => {}` notation instead of `function() {}`... This is a regression introduced in #768. Thanks @msymons for spotting it! Signed-off-by: nscuro --- .../accessmanagement/ApiKeyListGroupItem.vue | 8 ++++---- .../accessmanagement/EditApiKeyCommentModal.vue | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/views/administration/accessmanagement/ApiKeyListGroupItem.vue b/src/views/administration/accessmanagement/ApiKeyListGroupItem.vue index 8d7a984fc..79597c925 100644 --- a/src/views/administration/accessmanagement/ApiKeyListGroupItem.vue +++ b/src/views/administration/accessmanagement/ApiKeyListGroupItem.vue @@ -57,18 +57,18 @@ export default { EditApiKeyCommentModal, }, computed: { - keyId: () => { + keyId: function () { return MurmurHash2(this.apiKey.key).result(); }, - comment: () => { + comment: function () { return this.apiKey.comment ? this.apiKey.comment : 'No comment'; }, - createdTimestamp: () => { + createdTimestamp: function () { return this.apiKey.created ? common.formatTimestamp(this.apiKey.created, true) : 'N/A'; }, - lastUsedTimestamp: () => { + lastUsedTimestamp: function () { return this.apiKey.lastUsed ? common.formatTimestamp(this.apiKey.lastUsed, true) : 'N/A'; diff --git a/src/views/administration/accessmanagement/EditApiKeyCommentModal.vue b/src/views/administration/accessmanagement/EditApiKeyCommentModal.vue index 3132ba617..50f14c57b 100644 --- a/src/views/administration/accessmanagement/EditApiKeyCommentModal.vue +++ b/src/views/administration/accessmanagement/EditApiKeyCommentModal.vue @@ -50,7 +50,7 @@ export default { this.comment = this.apiKey.comment; }, methods: { - updateComment: () => { + updateComment: function () { this.axios .post( `${this.$api.BASE_URL}/${this.$api.URL_TEAM}/key/${this.apiKey.key}/comment`, @@ -70,7 +70,7 @@ export default { ); }); }, - resetValues: () => { + resetValues: function () { this.comment = null; }, },