Stop downloading when the tab is closed