Hi all
I have the following update action:
# PUT /music_artists/1 # PUT /music_artists/1.xml def update music_artist = MusicArtist.find(params[:id])
authorize_to!('EDIT', music_artist) do @page_title = "Edit #{music_artist.name}" respond_to do |format| if music_artist.update_attributes(params[:music_artist]) flash[:notice] = 'Party organisator was successfully updated.' format.html { redirect_to music_artist_url(@program) } format.xml { head :ok } else @music_artist = music_artist format.html { render :action => "edit" } format.xml { render :xml => @music_artist.errors.to_xml } end end end end
Strangely, after update I get redirected to the correct URL music_artists/123, but I'm getting the error "Unknown action"! It seems that the redirect is done using POST! But the show action needs GET!
So what's going on here? Thanks for infos, Josh