Remove extra spaces from keys