Fixed text replace maching by regular expression

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-expression-widget@111460 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Giancarlo Panichi 2015-01-23 09:39:56 +00:00
parent 3e36d4a604
commit 755093a259
1 changed files with 6 additions and 2 deletions

View File

@ -623,8 +623,12 @@ public class C_ExpressionParser {
C_TextReplaceMatchingRegex textReplaceMatchingRegex = (C_TextReplaceMatchingRegex) exp;
TDText tdRegexp = new TDText(textReplaceMatchingRegex.getRegexp()
.getValue());
TDText tdReplacing = new TDText(textReplaceMatchingRegex.getReplacing()
.getValue());
String replacement=textReplaceMatchingRegex.getReplacing().getValue();
if(replacement==null){
replacement="";
}
TDText tdReplacing = new TDText(replacement);
TextReplaceMatchingRegex textRepRegex = new TextReplaceMatchingRegex(
parse(textReplaceMatchingRegex.getToCheckText()), tdRegexp,