polishing background page script