Replaced deprecated chrome.tabs.getSelected by chrome.tabs.query