Skip to content
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
5 changes: 3 additions & 2 deletions app/preprints/-components/submit/supplements/component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ export default class Supplements extends Component<SupplementsArgs>{
@waitFor
public async removeSelectedProject(): Promise<void> {
try {
this.validate(false);
await this.args.manager.preprint.removeM2MRelationship('node'); // Remove relationship
// Remove relationship on the node side, this only clears the cache locally
this.args.manager.preprint.node.get('preprints')
Expand All @@ -89,7 +90,7 @@ export default class Supplements extends Component<SupplementsArgs>{
}

@action
public validate(): void {
this.args.manager.validateSupplements(true);
public validate(isValid = true): void {
this.args.manager.validateSupplements(isValid);
}
}