Issue 486 - make sure project character encoding doesn't get set to ""
git-svn-id: http://google-refine.googlecode.com/svn/trunk@2381 7d457c2a-affb-35e4-300a-418c747d4874
This commit is contained in:
parent
d5dd04965a
commit
80c13e4b59
@ -912,7 +912,12 @@ public class ImportingUtilities {
|
|||||||
) {
|
) {
|
||||||
ProjectMetadata pm = new ProjectMetadata();
|
ProjectMetadata pm = new ProjectMetadata();
|
||||||
pm.setName(JSONUtilities.getString(optionObj, "projectName", "Untitled"));
|
pm.setName(JSONUtilities.getString(optionObj, "projectName", "Untitled"));
|
||||||
pm.setEncoding(JSONUtilities.getString(optionObj, "encoding", "UTF-8"));
|
String encoding = JSONUtilities.getString(optionObj, "encoding", "UTF-8");
|
||||||
|
if ("".equals(encoding)) {
|
||||||
|
// encoding can be present, but empty, which won't trigger JSONUtilities default processing
|
||||||
|
encoding = "UTF-8";
|
||||||
|
}
|
||||||
|
pm.setEncoding(encoding);
|
||||||
|
|
||||||
record.parser.parse(
|
record.parser.parse(
|
||||||
project,
|
project,
|
||||||
|
Loading…
Reference in New Issue
Block a user