title: Heroku add record to sqlite
body: <p>I have just deployed my app to heroku, and after some problems, it seem to work.
  But then i try to add a record to an sqlite3 database from the app, it's not working, and isn't redirecting me to '/'.</p>
  
  <p>It's a sinatra app, i have installed all the data mapper dependencies, and the logs doesn't repost errors.
  here is the code</p>
  
  <pre><code>require 'rubygems'
  require 'sinatra'
  require 'dm-core'  
  require 'dm-timestamps'  
  require 'dm-validations'  
  require 'dm-migrations'
  DataMapper::setup(:default, "sqlite3://#{Dir.pwd}/rubrica.db")
  
  class Contatto  
    include DataMapper::Resource  
    property :id, Serial  
    property :fname, Text
    property :lname, Text
    property :phone, Text  
    property :mail, Text
  end  
  
  DataMapper.finalize.auto_upgrade!  
  
  get '/' do
      @title = 'Tutti'
    @Contatti = Contatto.all
      erb :home
  end
  
  get '/add' do
      @title = 'Aggiungi'
      erb :aggiungi
  end
  
  post '/' do
      c = Contatto.new
      c.fname = params[:fname]
  c.lname = params[:lname]
  c.phone = params[:phone]
  c.mail = params[:mail]
  c.save
  redirect '/'
  </code></pre>
  
  <p>end</p>
  
  <p>and the link
  <a href="http://rubrica.heroku.com" rel="nofollow">here</a></p>