Skip to content

Commit

Permalink
Merge pull request #5900 from BigFunger/share-as-embed-fix
Browse files Browse the repository at this point in the history
[share url] fixes embed links to re-add qs parameter
  • Loading branch information
spalger committed Jan 13, 2016
2 parents 670c53a + 964d083 commit 9661bc3
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/ui/public/share/directives/share_object_url.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,11 @@ app.directive('shareObjectUrl', function (Private, Notifier) {
};

$scope.getUrl = function () {
return $location.absUrl();
let url = $location.absUrl();
if ($scope.shareAsEmbed) {
url = url.replace('?', '?embed=true&');
}
return url;
};

$scope.$watch('getUrl()', updateUrl);
Expand Down

0 comments on commit 9661bc3

Please sign in to comment.