Fix metadata index