Skip to content

Commit 34f9b5e

Browse files
Fix/file guid (#277)
* feat(newbranch): test push * fix(file): add quid for file * fix(files): add file link component, refactoring * fix(files): update imports * fix(files): refactoring files * fix(files): refactoring files, fixed addons * Update src/app/shared/components/files-tree/files-tree.component.ts Co-authored-by: nsemets <nsemets@exoft.net> * fix(files): fixed loading --------- Co-authored-by: nsemets <nsemets@exoft.net>
1 parent 9d37a89 commit 34f9b5e

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

src/app/features/files/pages/files/files.component.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -207,12 +207,8 @@ export class FilesComponent {
207207
});
208208

209209
effect(() => {
210-
if (this.resourceType() === ResourceType.Registration) {
210+
if (!this.isConfiguredStorageAddonsLoading() && !this.isRootFoldersLoading()) {
211211
this.dataLoaded.set(true);
212-
} else {
213-
if (!this.isConfiguredStorageAddonsLoading() && !this.isRootFoldersLoading()) {
214-
this.dataLoaded.set(true);
215-
}
216212
}
217213
});
218214

src/app/shared/services/files.service.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { EMPTY, Observable, switchMap, throwError } from 'rxjs';
1+
import { Observable, of, switchMap, throwError } from 'rxjs';
22
import { catchError, map } from 'rxjs/operators';
33

44
import { HttpEvent } from '@angular/common/http';
@@ -296,7 +296,7 @@ export class FilesService {
296296
getConfiguredStorageAddons(resourceUri: string): Observable<ConfiguredStorageAddon[]> {
297297
return this.getResourceReferences(resourceUri).pipe(
298298
switchMap((referenceUrl: string) => {
299-
if (!referenceUrl) return EMPTY;
299+
if (!referenceUrl) return of([]);
300300

301301
return this.jsonApiService
302302
.get<GetConfiguredStorageAddonsJsonApi>(`${referenceUrl}/configured_storage_addons`)

0 commit comments

Comments
 (0)