File tree Expand file tree Collapse file tree 2 files changed +7
-12
lines changed Expand file tree Collapse file tree 2 files changed +7
-12
lines changed Original file line number Diff line number Diff line change 1717 "app-root-path" : " ^2.1.0" ,
1818 "chai" : " ^4.1.2" ,
1919 "chai-as-promised" : " ^7.1.1" ,
20- "collections" : " ^5.1.2" ,
2120 "jwt-simple" : " ^0.5.1" ,
2221 "memory-cache" : " ^0.2.0" ,
2322 "node-forge" : " >=1.0.0" ,
Original file line number Diff line number Diff line change 22
33var Constants = require ( '../util/Constants' ) ;
44var Logger = require ( '../logging/Logger' ) ;
5- var Map = require ( 'collections/map' ) ;
65var ApiException = require ( '../util/ApiException' ) ;
76var LogConfiguration = require ( '../logging/LogConfiguration' ) ;
87
@@ -514,17 +513,14 @@ MerchantConfig.prototype.defaultPropValues = function defaultPropValues() {
514513 hiddenPropertiesArray . push ( each . trim ( ) ) ;
515514 } ) ;
516515
517- var merchantMap = new Map ( Object . entries ( merchantConfig ) ) ;
518- //iterating the merchantConfig Object
519- merchantMap . forEach ( function ( value , key ) {
520- hiddenPropertiesArray . forEach ( function ( hide ) {
521- if ( key === hide ) {
522- merchantMap . delete ( key ) ;
523- }
524- } )
525- } ) ;
516+ const filteredMerchantConfig = { } ;
517+ for ( key in merchantConfig ) {
518+ if ( ! hiddenPropertiesArray . includes ( key ) ) {
519+ filteredMerchantConfig [ key ] = merchantConfig [ key ] ;
520+ }
521+ }
526522
527- return merchantMap . toObject ( ) ;
523+ return filteredMerchantConfig ;
528524 }
529525 if ( ! this . logConfiguration . isExternalLoggerSet ) {
530526 logger . clear ( ) ;
You can’t perform that action at this time.
0 commit comments