Browse Source

Merge pull request #125 from jskirst/scopeable-view

dynamically generate path based on resource scope
master
Dmitrii Golub 8 years ago committed by GitHub
parent
commit
d43c7d8aff
  1. 6
      app/views/devise/two_factor_authentication/show.html.erb

6
app/views/devise/two_factor_authentication/show.html.erb

@ -12,8 +12,8 @@
<% end %> <% end %>
<% if resource.direct_otp %> <% if resource.direct_otp %>
<%= link_to "Resend Code", resend_code_user_two_factor_authentication_path, action: :get %> <%= link_to "Resend Code", send("resend_code_#{resource_name}_two_factor_authentication_path"), action: :get %>
<% else %> <% else %>
<%= link_to "Send me a code instead", resend_code_user_two_factor_authentication_path, action: :get %> <%= link_to "Send me a code instead", send("resend_code_#{resource_name}_two_factor_authentication_path"), action: :get %>
<% end %> <% end %>
<%= link_to "Sign out", destroy_user_session_path, :method => :delete %> <%= link_to "Sign out", send("destroy_#{resource_name}_session_path"), :method => :delete %>

Loading…
Cancel
Save