param { [ Object ] } contractArray return { [ number ] } export const getAllowedNetworks = ( contractArray ) => { const numberOfContracts = contractArray . length ; const occurences = { } ; contractArray . forEach ( ( { networks } ) => { Object . keys ( networks ) . forEach ( networkId => { if ( networkId in occurences ) { occurences [ networkId ] ++ ; } else { occurences [ networkId ] = 1 ; } } ) ; } ) ; const allowedNetworks = [ ] ; Object . entries ( occurences ) . forEach ( ( [ networkId , occurence ] ) => { if ( occurence === numberOfContracts ) { allowedNetworks . push ( Number ( networkId ) ) ; } } ) ; return allowedNetworks ; } ;