Merged Kai's pull requests