fix(draw-route): fix support for pathname in sharable link

GitHub Pages hosts all websites under a namespace, a pathname.
For instance, `seasponge` in
http://mozilla.github.io/seasponge/

See #41
This commit is contained in:
Glavin Wiechert 2015-01-09 01:14:08 -04:00
Родитель 86f6b88f58
Коммит 7e8be46066
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -98,7 +98,7 @@ angular.module('seaspongeApp')
str = JSON.stringify(serialized)
data = encodeURIComponent(str)
# console.log(serialized, data)
link = "#{location.origin}/#/load?model=#{data}"
link = "#{location.origin}#{location.pathname}#/load?model=#{data}"
$scope.shareLink = link
# Drag'n'Drop Stencil support