Added support for empty value, fixed Save()