improved router to allow format detection for bridges