refactoring to handle wix keys the good way