Skip to content

Commit 358cbf5

Browse files
committed
Merge tag '25.4.1' into develop
Hotfix
2 parents 605da4c + b61a795 commit 358cbf5

File tree

3 files changed

+11
-6
lines changed

3 files changed

+11
-6
lines changed

src/app/features/preprints/store/preprint-stepper/preprint-stepper.state.ts

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -223,9 +223,14 @@ export class PreprintStepperState {
223223

224224
ctx.setState(patch({ preprintFile: patch({ isLoading: true }) }));
225225

226-
return this.fileService
227-
.updateFileContent(action.file, uploadedFile.links.upload)
228-
.pipe(switchMap(() => this.fileService.renameEntry(uploadedFile.links.upload, action.file.name, 'replace')));
226+
return this.fileService.updateFileContent(action.file, uploadedFile.links.upload).pipe(
227+
switchMap(() => {
228+
if (uploadedFile.name !== action.file.name) {
229+
return this.fileService.renameEntry(uploadedFile.links.upload, action.file.name, 'replace');
230+
}
231+
return EMPTY;
232+
})
233+
);
229234
}
230235

231236
@Action(FetchPreprintPrimaryFile)

src/app/features/project/overview/components/project-overview-toolbar/project-overview-toolbar.component.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,8 +178,8 @@ describe('ProjectOverviewToolbarComponent', () => {
178178
expect(component.ResourceType).toBe(ResourceType);
179179
});
180180

181-
it('should have resourceType set to Registration', () => {
182-
expect(component.resourceType).toBe(ResourceType.Registration);
181+
it('should have resourceType set to Project', () => {
182+
expect(component.resourceType).toBe(ResourceType.Project);
183183
});
184184
});
185185
});

src/app/features/project/overview/components/project-overview-toolbar/project-overview-toolbar.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ export class ProjectOverviewToolbarComponent {
6666

6767
isPublic = signal(false);
6868
isBookmarked = signal(false);
69-
resourceType = ResourceType.Registration;
69+
resourceType = ResourceType.Project;
7070

7171
bookmarksCollectionId = select(BookmarksSelectors.getBookmarksCollectionId);
7272
bookmarks = select(BookmarksSelectors.getBookmarks);

0 commit comments

Comments
 (0)