rebasing magic