commit before changing ajax work