Remove duplicate JS code for media gallery

local
Thor 2 years ago
parent bc8d4d0c78
commit 89a476f0bc
  1. 8
      app/javascript/mastodon/components/media_gallery.js

@ -92,14 +92,6 @@ class Item extends React.PureComponent {
let numCols = Math.ceil(root);
let numRows = Math.ceil(size / numCols);
let row = Math.floor(index / numCols);
if(row === numRows - 1) {
width = 100 / (1 + ((size - 1) % numCols));
} else {
width = 100 / numCols;
}
height = 100 / numRows;
let col = index % numCols;
let row = Math.floor(index / numCols);
if(row === numRows - 1) {

Loading…
Cancel
Save