Skip to content

Commit

Permalink
Merge tool-collections into staging
Browse files Browse the repository at this point in the history
  • Loading branch information
stage-branch-merger[bot] authored Aug 2, 2023
2 parents 2d59fa1 + 9987dcb commit 0b379d7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
7 changes: 5 additions & 2 deletions app/controllers/tool_groups_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,11 @@ def show

def destroy
tool_group = ToolGroup.find(params[:id])
tool_group.destroy!
head :no_content
if tool_group.destroy!
head :no_content
else
head :not_found
end
end

def update
Expand Down
2 changes: 1 addition & 1 deletion app/models/tool_group.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ class ToolGroup < ApplicationRecord
has_many :rule_languages, dependent: :destroy
has_many :rule_countries, dependent: :destroy
has_many :rule_praxes, class_name: "RulePraxis", dependent: :destroy
has_many :resource_tool_groups
has_many :resource_tool_groups, dependent: :destroy
has_many :resources, through: :resource_tool_groups
end

0 comments on commit 0b379d7

Please sign in to comment.