Fixed some issues with rebasing. The global count of revisions was not being determined properly, causing the rebase to fail. The global count now takes into account whether the revision belongs to a baseline event or not.