Skip to content

Commit

Permalink
Fixes Document Workspace Info Link error
Browse files Browse the repository at this point in the history
Ensures that `_unique` has value. This was previously throwing
an error, but given how `observeMultiple` works, it is expected that
`_unique` may be `undefined` when navigating away from the Info view.
  • Loading branch information
leekelleher authored and iOvergaard committed Nov 12, 2024
1 parent 5f1cb0e commit f916229
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,7 @@ export class UmbDocumentWorkspaceViewInfoLinksElement extends UmbLitElement {

async #requestUrls() {
if (this._isNew) return;

if (!this._unique) throw new Error('Document unique is required');
if (!this._unique) return;

const { data } = await this.#documentUrlRepository.requestItems([this._unique]);

Expand Down

0 comments on commit f916229

Please sign in to comment.