fixed a small bug with writing wrong settings key