Updated code with save button key-value compliance issue