Merged changes from upstream