diff --git a/tasks/inline.js b/tasks/inline.js index 07001bf..da8adcf 100644 --- a/tasks/inline.js +++ b/tasks/inline.js @@ -99,7 +99,7 @@ module.exports = function(grunt) { }).replace(//g, function(matchedWord, src){ var ret = matchedWord; - if(!isRemotePath(src) && src.indexOf(options.tag)!=-1){ + if(!isBase64Path(src) && !isRemotePath(src) && src.indexOf(options.tag)!=-1){ var inlineFilePath = path.resolve( path.dirname(filepath), src ).replace(/\?.*$/, ''); // 将参数去掉 @@ -116,7 +116,7 @@ module.exports = function(grunt) { }).replace(//g, function(matchedWord, src){ var ret = matchedWord; - if(!grunt.file.isPathAbsolute(src) && src.indexOf(options.tag)!=-1){ + if(!isBase64Path(src) && !grunt.file.isPathAbsolute(src) && src.indexOf(options.tag)!=-1){ var inlineFilePath = path.resolve( path.dirname(filepath), src ).replace(/\?.*$/, ''); // 将参数去掉