change observer to after_commit
added test_after_commit
use after_commit instead
refactor and allow custom observer
fix and refactor specs
Merge pull request #8 from alvinsj/use-after_commit

Use after commit, and allow custom observer