diff --git a/AltStore/News/NewsViewController.swift b/AltStore/News/NewsViewController.swift index e0ae7908..37b43ea7 100644 --- a/AltStore/News/NewsViewController.swift +++ b/AltStore/News/NewsViewController.swift @@ -453,6 +453,10 @@ extension NewsViewController: UICollectionViewDelegateFlowLayout return previousSize } + // Take layout margins into account. + self.prototypeCell.layoutMargins.left = self.view.layoutMargins.left + self.prototypeCell.layoutMargins.right = self.view.layoutMargins.right + let widthConstraint = self.prototypeCell.contentView.widthAnchor.constraint(equalToConstant: collectionView.bounds.width) NSLayoutConstraint.activate([widthConstraint]) defer { NSLayoutConstraint.deactivate([widthConstraint]) }