Fixes onSave error reported on #7