Fixed metadata disappearing issue