Ensuring Safe Visual Teach and Repeat Legged Navigation using Local World Representations