Adding root matching