<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,6 +1,6 @@
 class Topic &lt; ActiveRecord::Base
   
-  has_many :posts
+  has_many :posts, :dependent =&gt; :destroy
   belongs_to :forum, :counter_cache =&gt; true
   belongs_to :user, :counter_cache =&gt; true
   </diff>
      <filename>app/models/topic.rb</filename>
    </modified>
    <modified>
      <diff>@@ -21,9 +21,7 @@
 
 Merb.logger.info(&quot;Compiling routes...&quot;)
 Merb::Router.prepare do |r|
-  # RESTful routes
-  # r.resources :posts
-  
+
   r.resources :forums do |f|
     f.resources :topics do |t|
       t.resources :posts
@@ -37,11 +35,6 @@ Merb::Router.prepare do |r|
   r.match(&quot;/login&quot;).to(:controller =&gt; &quot;Sessions&quot;, :action =&gt; &quot;create&quot;).name(:login)
   r.match(&quot;/logout&quot;).to(:controller =&gt; &quot;Sessions&quot;, :action =&gt; &quot;destroy&quot;).name(:logout)
   r.resources :sessions
-  # This is the default route for /:controller/:action/:id
-  # This is fine for most cases.  If you're heavily using resource-based
-  # routes, you may want to comment/remove this line to prevent
-  # clients from calling your create or destroy actions with a GET
-  r.default_routes
   
   # Change this for your home page to be available at /
   r.match('/').to(:controller =&gt; 'forums', :action =&gt;'index')</diff>
      <filename>config/router.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>6ede814067cb3db9719fa986801e11e253c4c35f</id>
    </parent>
  </parents>
  <author>
    <name>Shay Arnett</name>
    <email>shayarnett@gmail.com</email>
  </author>
  <url>http://github.com/shayarnett/merbums/commit/71f1ac5d55402ad225f9d9bf9536d1a804c0f5af</url>
  <id>71f1ac5d55402ad225f9d9bf9536d1a804c0f5af</id>
  <committed-date>2008-06-04T11:13:43-07:00</committed-date>
  <authored-date>2008-06-04T11:13:43-07:00</authored-date>
  <message>fixed bug on index when deleting the last post in a forum</message>
  <tree>cd6b734c55db98a14d44b80f5a0106b48c037ac2</tree>
  <committer>
    <name>Shay Arnett</name>
    <email>shayarnett@gmail.com</email>
  </committer>
</commit>
