app/controllers/phcpress/article/posts_controller.rb in phcpress-53.0.0 vs app/controllers/phcpress/article/posts_controller.rb in phcpress-53.1.0

- old
+ new

@@ -32,28 +32,28 @@ # POST def create @article_post = Phcpress::Article::Post.new(article_post_params) @article_post.user_id = current_user.id if @article_post.save - redirect_to article_posts_url, notice: 'Post was successfully created.' + redirect_to article_posts_url, :flash => { :success => 'Post was successfully created.' } else render :new end end # PATCH/PUT def update if @article_post.update(article_post_params) - redirect_to article_posts_url, notice: 'Post was successfully updated.' + redirect_to article_posts_url, :flash => { :success => 'Post was successfully updated.' } else render :edit end end # DELETE def destroy @article_post.destroy - redirect_to article_posts_url, notice: 'Post was successfully destroyed.' + redirect_to article_posts_url, :flash => { :error => 'Post was successfully destroyed.' } end private # Use callbacks to share common setup or constraints between actions.