Implement a couple of suggestions from @jhamrick