template: remove dup js file in case of dup loading