edit metadata: send [], not ['']
This commit is contained in:
parent
996d3dc01f
commit
3c24b38ddf
1 changed files with 3 additions and 5 deletions
|
@ -285,14 +285,14 @@ oml.ui.infoView = function(externalData, isMixed) {
|
||||||
&& Ox.decodeHTMLEntities(value).split(separator).some(function(value) {
|
&& Ox.decodeHTMLEntities(value).split(separator).some(function(value) {
|
||||||
return Ox.endsWith(value, ' (Ed.)');
|
return Ox.endsWith(value, ' (Ed.)');
|
||||||
});
|
});
|
||||||
return Ox.unique(
|
return value ? Ox.unique(
|
||||||
Ox.decodeHTMLEntities(value).split(separator).map(function(value) {
|
Ox.decodeHTMLEntities(value).split(separator).map(function(value) {
|
||||||
value = Ox.encodeHTMLEntities(value);
|
value = Ox.encodeHTMLEntities(value);
|
||||||
return isEditor
|
return isEditor
|
||||||
? value.replace(/ \(Ed\.\)$/, '') + ' (Ed.)'
|
? value.replace(/ \(Ed\.\)$/, '') + ' (Ed.)'
|
||||||
: value;
|
: value;
|
||||||
})
|
})
|
||||||
);
|
) : [];
|
||||||
}
|
}
|
||||||
|
|
||||||
function toggleCoverSize(ratio) {
|
function toggleCoverSize(ratio) {
|
||||||
|
@ -738,9 +738,7 @@ oml.ui.infoView = function(externalData, isMixed) {
|
||||||
var edit = Ox.extend(
|
var edit = Ox.extend(
|
||||||
{id: !isMultiple ? data.id : ui.listSelection},
|
{id: !isMultiple ? data.id : ui.listSelection},
|
||||||
key,
|
key,
|
||||||
Ox.contains(arrayKeys, key)
|
Ox.contains(arrayKeys, key) ? splitValue(value, key) : value
|
||||||
? splitValue(value || '', key)
|
|
||||||
: value
|
|
||||||
);
|
);
|
||||||
if (!Ox.isEqual(edit[key], data[key])) {
|
if (!Ox.isEqual(edit[key], data[key])) {
|
||||||
data[key] = edit[key];
|
data[key] = edit[key];
|
||||||
|
|
Loading…
Reference in a new issue