Btw. this gets really nested - would make sense to extract to separated function, like "setupRedLinks" (in a similar way that section links and edit tab has its own function).