Check for string type before decode
This commit is contained in:
parent
ee6a5bffd5
commit
ea34856896
1 changed files with 1 additions and 1 deletions
|
@ -283,7 +283,7 @@ module External {
|
|||
// one to many
|
||||
if (isOneSide(field)) {
|
||||
let id = row[key][0]
|
||||
if (isNaN(id)) {
|
||||
if (typeof row[key] === "string") {
|
||||
id = decodeURIComponent(row[key]).match(/\[(.*?)\]/)?.[1]
|
||||
}
|
||||
newRow[field.foreignKey || linkTablePrimary] = breakRowIdField(id)[0]
|
||||
|
|
Loading…
Reference in a new issue