Would be good for the common forking logic to be encapsulated in a helper method.