When both groups contain the same fact, the fact gets cached only if the first group has TTLS. On the other hand, if only the second group has ttls, the fact won't get cached (because it is found in the first group and the TTLS for the first groups does not exist)