Skip to content

Commit c85f725

Browse files
authored
Merge pull request #63 from rishabhdixit/master
Refactored aspect ratio calculation logic, #127034935
2 parents 2bf14a4 + db864c7 commit c85f725

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

widget/index.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -624,8 +624,9 @@
624624
w = w / r;
625625
h = h / r;
626626
if (w < h) {
627-
w = h;
628-
h = w;
627+
w = w + h;
628+
h = w - h;
629+
w = w - h;
629630
}
630631

631632
return w / h;

0 commit comments

Comments
 (0)