Minor improvements

- Returning to correct browser tab when authentication finishes
- Removing unnessessary code block