cleanup sync_wal_helper - DRY