Fix content script errors