Skip to content
This repository has been archived by the owner on Nov 16, 2020. It is now read-only.

Commit

Permalink
Handle undefined URL in shovel status
Browse files Browse the repository at this point in the history
URLs can be undefined, e.g. after a refresh, this commit handles this
case to avoid displaying plain HTML in the cell.

Fixes #37
  • Loading branch information
acogoluegnes committed Jul 22, 2019
1 parent 4e13920 commit f36443e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions priv/www/js/tmpl/shovels.ejs
Expand Up @@ -50,10 +50,10 @@
<% } else { %>
<td><%= fmt_state('green', shovel.state) %></td>
<td><%= fmt_string(shovel.src_protocol) %></td>
<td><%= fmt_string(fmt_uri_with_credentials(shovel.src_uri)) %></td>
<td><%= shovel.src_uri == undefined ? fmt_string(shovel.src_uri) : fmt_string(fmt_uri_with_credentials(shovel.src_uri)) %></td>
<td><%= fmt_shovel_endpoint('src_', shovel) %></td>
<td><%= fmt_string(shovel.dest_protocol) %></td>
<td><%= fmt_string(fmt_uri_with_credentials(shovel.dest_uri)) %></td>
<td><%= shovel.dest_uri == undefined ? fmt_string(shovel.dest_uri) : fmt_string(fmt_uri_with_credentials(shovel.dest_uri)) %></td>
<td><%= fmt_shovel_endpoint('dest_', shovel) %></td>
<td><%= shovel.timestamp %></td>
<% } %>
Expand Down

0 comments on commit f36443e

Please sign in to comment.