Using uglify API instead of exec sync