Skip to content

Commit

Permalink
Update weird gift idea controller
Browse files Browse the repository at this point in the history
  • Loading branch information
jonallured committed Feb 22, 2024
1 parent 3c09717 commit c0bfcf1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/controllers/gift_ideas_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ class GiftIdeasController < ApplicationController

def update
if gift_idea.update(gift_idea_params)
flash.notice = "gift idea updated!"
redirect_to wishlist_path
flash.notice = "Gift Idea updated"
else
flash.alert = gift_idea.errors.full_messages
render :edit
flash.alert = gift_idea.errors.full_messages.to_sentence
end

redirect_to wishlist_path
end

private
Expand Down

0 comments on commit c0bfcf1

Please sign in to comment.