Added clear listener and cleaned up _db reference
Merge pull request #9 from mozilla-appmaker/db-clear-bug-fixes

Added clear listener and cleaned up _db reference