uncommented compactDatabase and fixed callback getting called twice on .new.