Implemented db:version and fixed db:migrate