Skip to content

Commit

Permalink
updated the search link param
Browse files Browse the repository at this point in the history
  • Loading branch information
fonsekaean committed Nov 17, 2018
1 parent 1313664 commit e6732fa
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Extensions/SearchDocumentGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,11 @@ public function getGenerateSearchLink()
{
$owner = $this->owner;
if(method_exists($owner, 'Link')) {
return $owner->Link() . '&SearchGen=1';
$link = $owner->Link();
if(strpos($link, '?') !== false) {
return $link . '&SearchGen=1';
}
return $link . '?SearchGen=1';
}
$class = get_class($owner);
throw new Exception(
Expand Down

0 comments on commit e6732fa

Please sign in to comment.