Robustifying frogs code.