Explorar o código

Merge pull request #1090 from Murii/patch-2

Fix for bug 1088
Juan Linietsky %!s(int64=10) %!d(string=hai) anos
pai
achega
1714828b54
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      core/dictionary.cpp

+ 2 - 0
core/dictionary.cpp

@@ -186,10 +186,12 @@ Error Dictionary::parse_json(const String& p_json) {
 
 	String errstr;
 	int errline=0;
+	if (p_json != ""){
 	Error err = JSON::parse(p_json,*this,errstr,errline);
 	if (err!=OK) {
 		ERR_EXPLAIN("Error parsing JSON: "+errstr+" at line: "+itos(errline));
 		ERR_FAIL_COND_V(err!=OK,err);
+		}
 	}
 
 	return OK;