Added more code to finish total to bridge