Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: thumbnail fetch error on OIDC logout #1060

Merged
merged 4 commits into from
May 17, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion src/app/datasets/dataset-table/dataset-table.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ import {
} from "state-management/actions/user.actions";
import { get } from "lodash";
import { AppConfigService } from "app-config.service";
import { selectCurrentUser } from "state-management/selectors/user.selectors";
export interface SortChangeEvent {
active: string;
direction: "asc" | "desc" | "";
Expand Down Expand Up @@ -232,7 +233,12 @@ export class DatasetTableComponent implements OnInit, OnDestroy, OnChanges {

this.subscriptions.push(
this.store.select(selectDatasets).subscribe((datasets) => {
this.datasets = datasets;
this.store.select(selectCurrentUser).subscribe((currentUser) => {
const publishedDatasets = datasets.filter(
(dataset) => dataset.isPublished
);
this.datasets = !!currentUser ? datasets : publishedDatasets;
});

// this.derivationMapPids = this.datasetDerivationsMaps.map(
// datasetderivationMap => datasetderivationMap.datasetPid
Expand Down