Need a better way to do this than having to commit all the time