mirror of
https://github.com/cocos/cocos4.git
synced 2026-12-02 00:22:43 +08:00
Merge pull request #455 from pandamicro/v1.0
Fix downloadText won't return error issue
This commit is contained in:
+1
-1
@@ -41,7 +41,7 @@ function downloadText (item, callback) {
|
||||
url = cc.Pipeline.UrlResolver.getRawUrl(url);
|
||||
|
||||
var result = jsb.fileUtils.getStringFromFile(url);
|
||||
if (typeof result === 'string') {
|
||||
if (result && typeof result === 'string') {
|
||||
callback(null, result);
|
||||
}
|
||||
else {
|
||||
|
||||
Reference in New Issue
Block a user