Fixed save code

The save code doesn’t break the program anymore.