removing branch pattern