fix(services): fix memory leaks in services.js