Fix brmsgw regex handling for dependecies