Skip to content

Commit

Permalink
fix: possible null image error
Browse files Browse the repository at this point in the history
  • Loading branch information
kristian-mkd committed Nov 8, 2024
1 parent f284cf5 commit 45d51f1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export const CookbookCard = ({ title, link, img }) => (
<h4 style={{ margin: '0px' }}>{title}</h4>
<a href={link}>
<p style={{ margin: '0', padding: '0' }}>
<img src={img} alt={title} />
{img && <img src={img} alt={title} />}
</p>
</a>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export const CookbookCard = ({ title, link, img }) => (
<h4 style={{ margin: '0px' }}>{title}</h4>
<a href={link}>
<p style={{ margin: '0', padding: '0' }}>
<img alt={title} src={img} />
{img && <img src={img} alt={title} />}
</p>
</a>
</div>
Expand Down

0 comments on commit 45d51f1

Please sign in to comment.