Browse Source

VLCMiniplaybackView: fix crash on < iOS11 with autolayout

The layoutGuides can be nil and crashh for <iOS 11 so we need to use self
Carola Nitz 7 years ago
parent
commit
7bfd54b82f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Sources/VLCMiniPlaybackView.m

+ 1 - 1
Sources/VLCMiniPlaybackView.m

@@ -116,7 +116,7 @@
     _stackView.distribution = UIStackViewDistributionFillEqually;
     [self addSubview:_stackView];
 
-    UILayoutGuide *guide = self.layoutGuides.firstObject;
+    UILayoutGuide *guide = self;
     if (@available(iOS 11.0, *)) {
         guide = self.safeAreaLayoutGuide;
     }