Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Steven <[email protected]>
  • Loading branch information
ijjk and styfle authored Oct 27, 2020
1 parent b61d85e commit d7e3b43
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion errors/next-image-unconfigured-host.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Add the `hostname` to your `images` config in `next.config.js`:
// next.config.js
module.exports = {
images: {
domains: [HOSTNAME_FROM_ERROR],
domains: ['assets.example.com'],
},
}
```
Expand Down
2 changes: 1 addition & 1 deletion packages/next/client/image.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,7 @@ function defaultLoader({ root, src, width, quality }: LoaderProps): string {

if (!configDomains.includes(parsedSrc.hostname)) {
throw new Error(
`Invalid src prop (${src}) on \`next/image\`, hostname is not configured under images in your \`next.config.js\`\n` +
`Invalid src prop (${src}) on \`next/image\`, hostname "${parsedSrc.hostname}" is not configured under images in your \`next.config.js\`\n` +
`See more info: https://err.sh/nextjs/next-image-unconfigured-host`
)
}
Expand Down

0 comments on commit d7e3b43

Please sign in to comment.