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

pkp/pkp-lib#282 Dataverse plugin: remove markup from dataset metadata #388

Merged
merged 3 commits into from
Jan 17, 2015

Conversation

jwhitney
Copy link

Some markup accepted in dataset metadata in Dataverse 3, but not in 4.

@@ -1171,7 +1171,7 @@ function createMetadataPackage($article) {
$package->addMetadata('description',
$article->getLocalizedData('studyDescription') ?
$article->getLocalizedData('studyDescription') :
$article->getLocalizedAbstract()
String::html2text($article->getLocalizedAbstract())
Copy link
Member

Choose a reason for hiding this comment

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

By the way, see http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=9056 -- deposits generally shouldn't be using the getLocalized... functions because those are dependent on the current user's locale, which means a depositor working e.g. in English will deposit different content from someone working e.g. in Spanish.

Better to use, for journal-level content, e.g...
$journal->getLocalizedSetting($journal->getPrimaryLocale())

For article-level content, e.g.:
$article->getTitle($article->getLocale())

Copy link
Member

Choose a reason for hiding this comment

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

(however, that's a general issue, so I won't hold back on merging this)

@asmecher asmecher mentioned this pull request Jan 14, 2015
@jwhitney
Copy link
Author

Changes made for copyright notice & metadata deposit locale.

asmecher added a commit that referenced this pull request Jan 17, 2015
pkp/pkp-lib#282 Dataverse plugin: remove markup from dataset metadata
@asmecher asmecher merged commit bd48a4e into pkp:ojs-dev-2_4 Jan 17, 2015
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