Hand merge code from my pals