From c4ddd08b0a30d8108796e51e79161a534db3aa1c Mon Sep 17 00:00:00 2001 From: chaos <72168435+qtchaos@users.noreply.github.com> Date: Sun, 1 Oct 2023 12:57:37 -0700 Subject: [PATCH] Fix license element deleting itself when pressing backspace. (#1389) --- pages/[type]/[id]/settings/license.vue | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/pages/[type]/[id]/settings/license.vue b/pages/[type]/[id]/settings/license.vue index ecca6bb37..9c5aab771 100644 --- a/pages/[type]/[id]/settings/license.vue +++ b/pages/[type]/[id]/settings/license.vue @@ -44,12 +44,12 @@ :close-on-select="true" :show-labels="false" :class="{ - 'known-error': license.short === '' && showKnownErrors, + 'known-error': license?.short === '' && showKnownErrors, }" :disabled="!hasPermission" /> @@ -253,6 +253,7 @@ export default defineNuxtComponent({ }, licenseId() { let id = '' + if (this.license === null) return id if ( (this.nonSpdxLicense && this.license.friendly === 'Custom') || this.license.short === 'All-Rights-Reserved' ||