Skip to content

Commit

Permalink
[PBM-1140] bugfix: physical restore fails with remapping (#843)
Browse files Browse the repository at this point in the history
  • Loading branch information
defbin committed Jul 4, 2023
1 parent e14f18d commit 32e2bb5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pbm/restore/physical.go
Original file line number Diff line number Diff line change
Expand Up @@ -1365,7 +1365,10 @@ func (r *PhysRestore) getShardMapping(bcp *pbm.BackupMeta) map[string]string {
targetRS, _, _ := strings.Cut(uri, "/")
sourceRS := mapRevRS(targetRS)
sourceS, ok := source[sourceRS]
if ok && sourceS != targetS {
if !ok {
sourceS = sourceRS
}
if sourceS != targetS {
rv[sourceS] = targetS
}
}
Expand Down

0 comments on commit 32e2bb5

Please sign in to comment.