turbolinks 0.1.1 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -9,6 +9,7 @@ visit = (url) ->
9
9
  fetchReplacement = (url) ->
10
10
  xhr = new XMLHttpRequest
11
11
  xhr.open 'GET', url, true
12
+ xhr.setRequestHeader 'Accept', 'text/html, application/xhtml+xml, application/xml'
12
13
  xhr.onload = -> fullReplacement xhr.responseText, url
13
14
  xhr.send()
14
15
 
@@ -38,7 +39,7 @@ replaceHTML = (html) ->
38
39
 
39
40
  extractLink = (event) ->
40
41
  link = event.target
41
- until link is this or link.nodeName is 'A'
42
+ until link is document or link.nodeName is 'A'
42
43
  link = link.parentNode
43
44
  link
44
45
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: turbolinks
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: