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

tweak copy embed #18

Merged
merged 1 commit into from
Apr 16, 2024
Merged

tweak copy embed #18

merged 1 commit into from
Apr 16, 2024

Conversation

petrjasek
Copy link
Member

@petrjasek petrjasek commented Apr 11, 2024

  • read article id from parent as well
  • fix server tests

uses superdesk/newsroom-core#880

@@ -18,7 +19,7 @@ registerExtensions({
continue;
}

const licenseName = (embeddedArticle.subject ?? []).find(({scheme}) => scheme === 'licence_type')?.name;
const licenseName = (embeddedArticle.subject ?? []).find(({scheme}) => scheme === 'licence_type')?.name ?? 'Creative Commons';

if (licenseName == null) {
Copy link
Collaborator

@MarkLark86 MarkLark86 Apr 11, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Considering licenseName will always contain a value now, this if statement would never be reached

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep this is more for testing when there is no such cv

@petrjasek petrjasek merged commit 7cc97f0 into develop Apr 16, 2024
11 checks passed
@petrjasek petrjasek deleted the copy-embed-code branch April 16, 2024 09:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants