refactor: add license header to JS files & format files (#12035)

This commit is contained in:
Victor Berchet
2016-10-04 13:15:49 -07:00
committed by Chuck Jazdzewski
parent b64b5ece65
commit 8310c91823
73 changed files with 1174 additions and 948 deletions

View File

@ -1,4 +1,12 @@
"use strict";
/**
* @license
* Copyright Google Inc. All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
'use strict';
var fs = require('fs');
var path = require('path');
@ -45,11 +53,11 @@ function _checkCache(markerFile, cacheMarkerFile) {
* pull in existing module.
*/
function _deleteDir(path) {
if( fs.existsSync(path) ) {
if (fs.existsSync(path)) {
var subpaths = fs.readdirSync(path);
subpaths.forEach(function(subpath) {
var curPath = path + "/" + subpath;
if(fs.lstatSync(curPath).isDirectory()) {
var curPath = path + '/' + subpath;
if (fs.lstatSync(curPath).isDirectory()) {
_deleteDir(curPath);
} else {
fs.unlinkSync(curPath);