fixed a bug that did not allow the value `0` to be saved