Skip to content

Commit

Permalink
Show error message when file can not be loaded
Browse files Browse the repository at this point in the history
  • Loading branch information
abdul-alhasany committed Jun 23, 2022
1 parent bd9d013 commit e51a3e0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions index.js
Expand Up @@ -29,6 +29,7 @@ module.exports = function svgLoader (options = {}) {
try {
svg = await fs.readFile(path, 'utf-8')
} catch (ex) {
console.log("File couldn't be loaded, fallback to default loader", id, ex)
return // File couldn't be loaded, fallback to default loader
}

Expand Down

0 comments on commit e51a3e0

Please sign in to comment.