Update position when scope changes

After discussion on #19, I tried to fix that issue.