From 502d4185fa8e0f62d48fe4c70b5cc55c9f0a04ca Mon Sep 17 00:00:00 2001
From: Neil Smith <neil.git@njae.me.uk>
Date: Mon, 6 Jan 2014 11:40:44 +0000
Subject: [PATCH] Display and forms seem to work

---
 app/views/feed/index.html.erb | 2 +-
 app/views/feed/show.html.erb  | 2 +-
 config/routes.rb              | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/app/views/feed/index.html.erb b/app/views/feed/index.html.erb
index 8ffe638..9bd98c6 100644
--- a/app/views/feed/index.html.erb
+++ b/app/views/feed/index.html.erb
@@ -1,6 +1,6 @@
 <h1>Feeds available</h1>
 
-<% form_tag :action => 'update' do %>
+<%= form_tag update_path do %>
   <p>Set feed <%= text_field_tag :feed_name, '', :size => 20 %>
     to include <%= text_field_tag :title, '', :size => 30 %>
     containing  <%= text_field_tag :description, '', :size => 50 %>
diff --git a/app/views/feed/show.html.erb b/app/views/feed/show.html.erb
index a491835..789debd 100644
--- a/app/views/feed/show.html.erb
+++ b/app/views/feed/show.html.erb
@@ -1,7 +1,7 @@
 <h1>Contents of feed <%= h params[:feed_name] %></h1>
 <p><%= link_to("List of all feeds", index_path) %></p>
 
-<% form_tag :action => 'update' do %>
+<%= form_tag update_path do %>
   <p>Set feed <%= text_field_tag :feed_name, h(params[:feed_name]), :size => 20 %>
     to include <%= text_field_tag :title, '', :size => 30 %>
     containing  <%= text_field_tag :description, '', :size => 50 %>
diff --git a/config/routes.rb b/config/routes.rb
index 4b69b19..8b7c093 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -8,7 +8,7 @@ Feedcatcher::Application.routes.draw do
   
   get 'index', to: 'feed#index', as: :index
   get ':feed_name', to: 'feed#show', as: :feed
-  post '*ignored', to: 'feed#update', as: :update
+  post '', to: 'feed#update', as: :update
 
   # Example of regular route:
   #   get 'products/:id' => 'catalog#view'
-- 
2.43.0