Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Commit

Permalink
Use more up to date url when avail
Browse files Browse the repository at this point in the history
Auditors: @bsclifton

This goes along with last commit, it's better to use the url provided than what is in our props in case it wasn't updated yet
  • Loading branch information
bbondy committed Jan 26, 2017
1 parent b9c2cce commit 84d0eb5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions js/components/frame.js
Original file line number Diff line number Diff line change
Expand Up @@ -820,7 +820,7 @@ class Frame extends ImmutableComponent {
return
}
windowActions.onWebviewLoadEnd(this.frame, url)
const parsedUrl = urlParse(this.props.location)
const parsedUrl = urlParse(url)
if (!this.allowRunningWidevinePlugin()) {
this.showWidevineNotification(this.props.location, this.origin, () => {
}, () => {
Expand All @@ -836,8 +836,8 @@ class Frame extends ImmutableComponent {
appActions.addSite(siteUtil.getDetailFromFrame(this.frame))
}

if (this.props.location.startsWith(pdfjsOrigin)) {
let displayLocation = UrlUtil.getLocationIfPDF(this.props.location)
if (url.startsWith(pdfjsOrigin)) {
let displayLocation = UrlUtil.getLocationIfPDF(url)
windowActions.setSecurityState(this.frame, {
secure: urlParse(displayLocation).protocol === 'https:',
runInsecureContent: false
Expand Down

0 comments on commit 84d0eb5

Please sign in to comment.