Skip to content

Commit

Permalink
Only link to search result when we have the result (#26)
Browse files Browse the repository at this point in the history
  • Loading branch information
soulgalore authored Jun 20, 2024
1 parent 85d208a commit 88c6963
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion server/views/search.pug
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,10 @@ block content
td
span.icon-text
span
a(href=test.result_url) #{test.url ? shortURL(test.url, true) : test.scripting_name}
if test.result_url
a(href=test.result_url) #{test.url ? shortURL(test.url, true) : test.scripting_name}
else
span #{test.url ? shortURL(test.url, true) : test.scripting_name}
- let urlOnClick = test.url ? `addToSearch('url:${test.url}')` : `addToSearch('name:${ test.scripting_name}')`;
a(role='button' onclick=urlOnClick)
span.icon.is-small
Expand Down

0 comments on commit 88c6963

Please sign in to comment.