made sure no middleware is added twice, fixes joinbox/cornercard-issues#375