Skip to content

Commit

Permalink
Use optional chaining instead of traditional nullish check
Browse files Browse the repository at this point in the history
Co-authored-by: Jacob Nesbitt <jjnesbitt2@gmail.com>
  • Loading branch information
waxlamp and jjnesbitt authored Oct 4, 2023
1 parent d9b9283 commit cc0c545
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion web/src/views/FileBrowserView/FileBrowser.vue
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ const updating = ref(false);
// Computed
const owners = computed(() => store.owners?.map((u) => u.username) || null);
const currentDandiset = computed(() => store.dandiset);
const embargoed = computed(() => currentDandiset.value && currentDandiset.value.dandiset.embargo_status === 'EMBARGOED');
const embargoed = computed(() => currentDandiset.value?.dandiset.embargo_status === 'EMBARGOED');
const splitLocation = computed(() => location.value.split('/'));
const isAdmin = computed(() => dandiRest.user?.admin || false);
const isOwner = computed(() => !!(
Expand Down

0 comments on commit cc0c545

Please sign in to comment.