Skip to content

Commit

Permalink
revert changes of GDB-8336
Browse files Browse the repository at this point in the history
What
Reverts the changes introduced to address the GDB-8336 issue.

Why
Added escaping to double quotes adds extra character in user data.

How
Removes the previously added double quote escaping.
  • Loading branch information
boyan-tonchev committed Oct 26, 2023
1 parent cdc6c5a commit 07734fa
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/js/angular/explore/statements.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,10 @@ function StatementsService() {
for (let j = 0; j < value.length; j++) {
const statement = value[j];
data += '\n\t<' + statement.subject + '> <' + statement.predicate + '> ';
let statementObjectValue = statement.object.value;
if (statement.object.type === 'uri') {
data += '<' + statementObjectValue + '> .';
data += '<' + statement.object.value + '> .';
} else {
statementObjectValue = statementObjectValue.replace(/"/g, '\\"');
data += '"""' + statementObjectValue + '"""' + (statement.object.datatype ? '^^<' + statement.object.datatype + '>' : (statement.object.lang ? '@' + statement.object.lang : '')) + ' .';
data += '"""' + statement.object.value + '"""' + (statement.object.datatype ? '^^<' + statement.object.datatype + '>' : (statement.object.lang ? '@' + statement.object.lang : '')) + ' .';
}
}

Expand Down

0 comments on commit 07734fa

Please sign in to comment.