split up background.js file