Now that you've fixed this up so it works with mesh adaptivity you should be able to remove these branches from all of the Richards stuff...