Yes, this is definitely the more rational conclusion. Even if no one knew about germ theory or parasites there were likely observations made that certain foods/preparations resulted in certain outcomes and then codified this information in the laws. It seems that the grandparent comment is starting from the premise that god exists and looking for evidence to support the conclusion they already hold.