File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -769,6 +769,8 @@ Compilation.prototype.createHash = function createHash() {
769769 var hashDigest = outputOptions . hashDigest ;
770770 var hashDigestLength = outputOptions . hashDigestLength ;
771771 var hash = require ( "crypto" ) . createHash ( hashFunction ) ;
772+ if ( outputOptions . hashSalt )
773+ hash . update ( outputOptions . hashSalt ) ;
772774 this . mainTemplate . updateHash ( hash ) ;
773775 this . chunkTemplate . updateHash ( hash ) ;
774776 this . moduleTemplate . updateHash ( hash ) ;
@@ -782,6 +784,8 @@ Compilation.prototype.createHash = function createHash() {
782784 for ( i = 0 ; i < chunks . length ; i ++ ) {
783785 chunk = chunks [ i ] ;
784786 var chunkHash = require ( "crypto" ) . createHash ( hashFunction ) ;
787+ if ( outputOptions . hashSalt )
788+ hash . update ( outputOptions . hashSalt ) ;
785789 chunk . updateHash ( chunkHash ) ;
786790 if ( chunk . entry ) {
787791 this . mainTemplate . updateHashForChunk ( chunkHash , chunk ) ;
You can’t perform that action at this time.
0 commit comments