This repository was archived by the owner on May 1, 2020. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 5
5
convertDeepLinkConfigEntriesToString ,
6
6
getUpdatedAppNgModuleContentWithDeepLinkConfig ,
7
7
filterTypescriptFilesForDeepLinks ,
8
+ hasExistingDeepLinkConfig ,
8
9
purgeDeepLinkDecorator
9
10
} from './deep-linking/util' ;
10
11
import { Logger } from './logger/logger' ;
@@ -50,8 +51,10 @@ export function transformTsForDeepLinking(context: BuildContext) {
50
51
tsFile . content = purgeDeepLinkDecorator ( tsFile . content ) ;
51
52
} ) ;
52
53
const tsFile = context . fileCache . get ( getStringPropertyValue ( Constants . ENV_APP_NG_MODULE_PATH ) ) ;
53
- const deepLinkString = convertDeepLinkConfigEntriesToString ( getParsedDeepLinkConfig ( ) ) ;
54
- tsFile . content = getUpdatedAppNgModuleContentWithDeepLinkConfig ( tsFile . path , tsFile . content , deepLinkString ) ;
54
+ if ( ! hasExistingDeepLinkConfig ( tsFile . path , tsFile . content ) ) {
55
+ const deepLinkString = convertDeepLinkConfigEntriesToString ( getParsedDeepLinkConfig ( ) ) ;
56
+ tsFile . content = getUpdatedAppNgModuleContentWithDeepLinkConfig ( tsFile . path , tsFile . content , deepLinkString ) ;
57
+ }
55
58
}
56
59
return Promise . resolve ( ) ;
57
60
}
You can’t perform that action at this time.
0 commit comments