Json metadata: fix infinite loop on previous commit