Skip to content

Commit

Permalink
Merge pull request TheWidlarzGroup#1395 from react-native-community/b…
Browse files Browse the repository at this point in the history
…ugfix/maxbitrate-apply-mods

Fix iOS video not displaying after switching source
  • Loading branch information
cobarx committed Dec 22, 2018
2 parents bd3d6d8 + 75b07d7 commit 478c135
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions ios/Video/RCTVideo.m
Original file line number Diff line number Diff line change
Expand Up @@ -858,7 +858,7 @@ - (void)setVolume:(float)volume

- (void)setMaxBitRate:(float) maxBitRate {
_maxBitRate = maxBitRate;
[self applyModifiers];
_playerItem.preferredPeakBitRate = maxBitRate;
}


Expand All @@ -872,8 +872,7 @@ - (void)applyModifiers
[_player setMuted:NO];
}

_playerItem.preferredPeakBitRate = _maxBitRate;

[self setMaxBitRate:_maxBitRate];
[self setSelectedAudioTrack:_selectedAudioTrack];
[self setSelectedTextTrack:_selectedTextTrack];
[self setResizeMode:_resizeMode];
Expand Down

0 comments on commit 478c135

Please sign in to comment.