Revert "Revert afaa98a..6f3b730"

This reverts commit 0e690b8494ab9848965c93d753075f22f55b4fcf.
Fixed merge issues