Please stay in touch just in case.

Literal

By-chance [for-に備えて] contact [object-を] maintain-[polite request-てください].

Here 万一 stands alone without 場合 or 時, paired directly with に備えて. 連絡をたもつ ('to maintain contact') uses たもつ (保つ, 'to maintain, to keep') — a formal verb for sustained states. More formal than the everyday 連絡を取る.