Skip to content
This repository has been archived by the owner on Jan 19, 2023. It is now read-only.

Commit

Permalink
fix: Default to null height instead of 0
Browse files Browse the repository at this point in the history
correction for pull request #66, use 'null' instead of '0'
  • Loading branch information
fritz-c committed Sep 7, 2017
2 parents f57bedb + baccb9f commit faa996c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/react-image-lightbox.js
Original file line number Diff line number Diff line change
Expand Up @@ -1321,8 +1321,8 @@ class ReactImageLightbox extends Component {
return;
}

imageStyle.width = (isNaN(bestImageInfo.width)) ? 0 : bestImageInfo.width;
imageStyle.height = (isNaN(bestImageInfo.height)) ? 0 : bestImageInfo.height;
imageStyle.width = isNaN(bestImageInfo.width) ? null : bestImageInfo.width;
imageStyle.height = isNaN(bestImageInfo.height) ? null : bestImageInfo.height;

const imageSrc = bestImageInfo.src;
if (discourageDownloads) {
Expand Down

0 comments on commit faa996c

Please sign in to comment.