Skip to content

Commit

Permalink
Fixes for Project Alias delete routes
Browse files Browse the repository at this point in the history
  • Loading branch information
mo-nathan committed Jan 18, 2025
1 parent 339eb57 commit ea2d105
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/controllers/projects/aliases_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def destroy
@project_alias.destroy
respond_to do |format|
format.html do
redirect_to(project_aliases_pat(project_id:),
redirect_to(project_aliases_path(project_id:),
notice: :project_alias_deleted.t)
end
format.json { head(:no_content) }
Expand Down
3 changes: 2 additions & 1 deletion app/views/controllers/projects/aliases/index.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@
<td>
<%= link_to('Show', project_alias_path(project_id:, id: project_alias.id)) %>
<%= link_to('Edit', edit_project_alias_path(project_id:, id: project_alias.id)) %>
<%= link_to('Delete', project_alias_path(project_id:, id: project_alias.id), method: :delete, data: { confirm: 'Are you sure?' }) %>
<%= link_to('Delete', project_alias_path(project_id:, id: project_alias.id),
data: { turbo_method: :delete, turbo_confirm: 'Are you sure?' }) %>
</td>
</tr>
<% end %>
Expand Down

0 comments on commit ea2d105

Please sign in to comment.